public class DatasetProducer
extends java.lang.Object
Parses a pair of log files produced by a traffic publisher and traffic
reflector, and produces a final dataset to use for packet arrival prediction.
If the file specified for the dataset already exists, the new data will be
appended to the end of the file; otherwise, a new file will be created.
Information in the dataset includes the bandwidth, size of each packet sent
(in bytes), jitter (based on two consecutive transmissions), latency for each
packet (in ms), packet loss rate, original rate of traffic generation (in
ms/packet), the hour of the day each packet was sent, the day of the week
each packet was sent, the timestamp in milliseconds, and the desired predicted
next arrival time (in ms from the current packet arrival).
Each entry in the resulting dataset consists of a comma separated line of
values, in the following order:
timestamp, hour, day, rate, size, bandwidth, latency, jitter, packet loss, prediction
Jitter is calculated from the latencies found in the provided traffic
publisher log file. Hour of day and day of week are determined from the
timestamps in the log file. Packet size, packet loss rate, and latency are
echoed directly from the log file.
The prediction is calculated from the provided traffic reflector log file.
The predicted value for a given entry is: (next arrival time - current
arrival time).
The bandwidth is (for now) an assumed value, specified by a command line
argument.
The original rate of stream generation is specified by a command line
argument.
Takes five command line arguments:
pInputFile - path to the desired traffic publisher log file
rInputFile - path to the desired (and presumably corresponding to pInputFile)
traffic reflector log file
outputFile - desired path to the produced dataset
bandwidth - value to use for the bandwidth in each entry (in mBits/s)
trafficRate - value to use for the original rate of traffic generation for
each entry (in number of ms between packets)
- Author:
- Kira Lindburg