Skip to content

Script designed to plot graphs out of SRT core statistics

Notifications You must be signed in to change notification settings

mbakholdina/srt-stats-plotting

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

srt-stats-plotting

Code style: black

Script designed to plot graphs out of SRT core statistics.

SRT stands for Secure Reliable Transport and is an open source transport technology that optimizes streaming performance across unpredictable networks, such as the Internet.

Requirements

To install the library dependencies run:

pip install -r requirements.txt

Script Usage

The main purpose of plot_srt_stats.py script is to visualize SRT core statistics produced during experiments by one of the testing applications like srt-xtransmit and srt-live-transmit or third-party solutions supporting SRT protocol. Depending on whether this statistics is collected on sender or receiver side, the data plotted may vary.

SRT core statistics should be collected in a .csv file. Usually, as a naming convention rule the file name ends either on "-snd" or "-rcv" depending on the side (sender or receiver) where the data was collected. Or, file name can just contain "snd" or "rcv" part in it.

Statistics filepath is passed as an argument to a script. Script usage

plot_srt_stats.py [OPTIONS] STATS_FILEPATH

Use --help option in order to get the full list of options

--is-sender   Should be set if sender statistics is provided. Otherwise, it
              is assumed that receiver statistics is provided.
--is-fec      Should be set if packet filter (FEC) stats is enabled.
--export-png  Export plots to .png files.
--help        Show this message and exit.

Usage with srt-live-transmit

For the usage with srt-live-transmit, make sure that the export of SRT statistics is enabled in .csv format. This can be done by passing the following parameters:

  • -statspf:csv to ensure the CSV format is used when exporting.
  • -statsout:/path/to/desired/folder/filename-rcv.csv to define where to write the statistics
  • -stats-report-frequency:1000 to define how often to write statistics (per # of packets), this example sets it to once per thousand packets.

More information on srt-live-transmit's command line parameters can be found here.

Plots Description

Note: Megabytes and Rate plots correlation is determined by the following formula

Rate (Mbps) = MB / interval (s),

where interval is the interval indicating how frequently the statistics is collected (in seconds).

Example Plots

The script plots different charts from SRT statistics. Examples of .csv files and corresponding .html output can be found in the examples folder. For example, a chart to visualize statistics on the packets being sent, lost, retransmitted, dropped or on flight:

packets_1

The legends are interactive. You can click, e.g., on Dropped and On Flight to disable the respective plots:

packets_2

Another chart illustrates the sending rate in Mbps:

sending_rate_mbps

Available size of the sender's buffer helps to detect if there is enough space to store outgoing data, or the source generates data faster then SRT can transmit:

available_snd_buffer_size

About

Script designed to plot graphs out of SRT core statistics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages