aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjörn B. Brandenburg <bbb@cs.unc.edu>2010-03-19 10:22:37 -0400
committerBjörn B. Brandenburg <bbb@cs.unc.edu>2010-03-19 10:22:37 -0400
commit47c9d5df446cd06ae566126135e26cb9279b35f2 (patch)
tree8b3e98d8f14154f8b68943ea8558e84a9a88ebcd
parentfbfac3ea825a863400f7196750f016b6a6a0d48d (diff)
Add small example.
-rw-r--r--README33
-rw-r--r--example.csv106
2 files changed, 139 insertions, 0 deletions
diff --git a/README b/README
new file mode 100644
index 0000000..3abde32
--- /dev/null
+++ b/README
@@ -0,0 +1,33 @@
1This is a simple, quick-n-dirty wrapper for plotting .csv files with
2Gnuplot.
3
4The tool will remove comments (lines starting with a '#' character) before
5passing the data to Gnuplot. This makes it possible to have experimental
6setup and date information encoded in the .csv file, which is beneficial
7for archival reasons.
8
9You can plot the example file to a PNG graph using the following command:
10
11./gnuplot.py -o example -f png --xlabel "Time" --ylabel "Supply Bound" \
12 example.csv 1 2 "Supply Bound Function"
13
14
15In general, each curve that you want to plot in a graph is defined by four
16arguments:
17
18./gnuplot.py [OPTIONS] \
19 <file1> <xcolumn1> <ycolumn1> <title1> \
20 <file2> <xcolumn2> <ycolumn2> <title2> \
21 ... and so on ...
22
23For large experiments with many graphs, it is more convenient to wrap gnuplot.py
24in a project-specific plotting script. Have a look at plot.py and plot_ohead.py
25to see how I did it. Basically, the scrips infer what to plot and how to name
26and label the graphs from the name of each .csv file.
27
28For example, the file name 'hard_rtss09_dist=uni_medium_250.csv' encodes the
29following information: 1) it uses hard real-time schedulability tests, it was
30using the RTSS'09 experimental setup and overheads, the task sets were generated
31with uniform utilization from the range [0.1, 0.4] (medium), and periods were
32distributed uniformly in [50, 250]. This is parsed by plot.py, which then
33calls gnuplot.py to generate a graph with the correct labels and settings.
diff --git a/example.csv b/example.csv
new file mode 100644
index 0000000..0c70bd7
--- /dev/null
+++ b/example.csv
@@ -0,0 +1,106 @@
1# This is the result of sampling a simple supply bound function.
2# As defined in Sanjoy's G-EDF paper.
3
4# first column: time
5# second column: supply bound
60, 0.000000
71, 0.000000
82, 0.000000
93, 0.000000
104, 0.000000
115, 0.000000
126, 0.000000
137, 0.000000
148, 0.000000
159, 0.000000
1610, 0.000000
1711, 0.000000
1812, 0.000000
1913, 0.000000
2014, 0.000000
2115, 1.000000
2216, 5.000000
2317, 9.000000
2418, 9.000000
2519, 9.000000
2620, 9.000000
2721, 9.000000
2822, 9.000000
2923, 9.000000
3024, 9.000000
3125, 10.000000
3226, 14.000000
3327, 18.000000
3428, 18.000000
3529, 18.000000
3630, 18.000000
3731, 18.000000
3832, 18.000000
3933, 18.000000
4034, 18.000000
4135, 19.000000
4236, 23.000000
4337, 27.000000
4438, 27.000000
4539, 27.000000
4640, 27.000000
4741, 27.000000
4842, 27.000000
4943, 27.000000
5044, 27.000000
5145, 28.000000
5246, 32.000000
5347, 36.000000
5448, 36.000000
5549, 36.000000
5650, 36.000000
5751, 36.000000
5852, 36.000000
5953, 36.000000
6054, 36.000000
6155, 37.000000
6256, 41.000000
6357, 45.000000
6458, 45.000000
6559, 45.000000
6660, 45.000000
6761, 45.000000
6862, 45.000000
6963, 45.000000
7064, 45.000000
7165, 46.000000
7266, 50.000000
7367, 54.000000
7468, 54.000000
7569, 54.000000
7670, 54.000000
7771, 54.000000
7872, 54.000000
7973, 54.000000
8074, 54.000000
8175, 55.000000
8276, 59.000000
8377, 63.000000
8478, 63.000000
8579, 63.000000
8680, 63.000000
8781, 63.000000
8882, 63.000000
8983, 63.000000
9084, 63.000000
9185, 64.000000
9286, 68.000000
9387, 72.000000
9488, 72.000000
9589, 72.000000
9690, 72.000000
9791, 72.000000
9892, 72.000000
9993, 72.000000
10094, 72.000000
10195, 73.000000
10296, 77.000000
10397, 81.000000
10498, 81.000000
10599, 81.000000
106