As a network behaviour demonstration, I did a repeated clone-out of a Git repository, writing its timestamp data with date '+%F %T'
in columns one and two (start and end times) of a CSV
This Python script processes that CSV to produce a plot of the durations:
- timedeltas calculated using
datetime
- plotting using
matplotlib.pyplot
- adding labels at spaced out intervals, and rotated
The clone test is looping_clones.sh
which does a clone of a "large" repo every 10min. It includes start times, end times, and such in human-readable form as "comments", and non-commented lines to serve as CSV data
extract_clonetest_csv.sh
isolates that data into a CSV file proper, and produces a Base64 encoded tarball of that data - this was for easy copy-pasting the file out to another machine via clipboard (needs must....)
It is unpacked to local directory by running base64 -di | tar xz
, pasting the data, and hitting CTRL + D
to terminate input. Only works in Unix shell environments like bash, sh, ksh, etc and Windows Git Bash.