scalability stuff

This commit is contained in:
Stephen McQuay 2011-05-25 19:56:54 -06:00
parent 07e8c67118
commit ada569a621
4 changed files with 88 additions and 0 deletions

25
plots/analyze.py Normal file
View File

@ -0,0 +1,25 @@
import sys
import shelve
s = shelve.open(sys.argv[1])
d = dict(s)
s.close()
# {'count': 10000, 'extra': 256, 'receive': 1148.0290439128876, 'submit': 4.298105001449585, 'participants': 1, 'order': 5}
# 'tasks': defaultdict(<type 'int'>, {'m5-2-1.local-31671': 10000}),
for line in (i[1] for i in sorted(d.iteritems(), key = lambda x: x[1]['stats']['participants'])):
run = line['stats']
velocity = run['count'] / run['receive']
# print run['participants'], run['count'] / run['receive']
# inverse
# print run['participants'], run['receive'] / run['count']
# speedup:
S_p = run['receive']/run['count'] / 1148.02904
print run['participants'], velocity, S_p

View File

@ -0,0 +1,35 @@
import sys
import shelve
import pickle
import numpy as np
import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
if len(sys.argv) != 2:
print "usage: %s <interp.shelve>" % sys.argv[0]
sys.exit(1)
s = shelve.open(sys.argv[1])
d = dict(s)
s.close()
c = 0
for line in (i[1] for i in sorted(d.iteritems(), key = lambda x: x[1]['stats']['participants'])):
c += 1
run = line['stats']
x = np.array(run['tasks'].values())
# the histogram of the data
plt.figure(c)
plt.title("Histogram of Interpolation Performance")
plt.xlabel("Number of Interpolations Performed")
plt.ylabel("Number of minions")
n, bins, patches = plt.hist(x) # , 50, normed=1, facecolor='green', alpha=0.5)
plt.grid(True)
output_file_name = 'asdf.%0.3d.%d.png' % (run['participants'], str(run['count']).count("0"))
plt.savefig(output_file_name)

17
plots/scale.out Normal file
View File

@ -0,0 +1,17 @@
1 8.71058101972 0.000100000000341
2 16.9174102062 5.14888564103e-05
4 33.8342624632 2.57448527477e-05
5 41.369278595 2.10556754801e-05
8 70.8631618899 1.22921145728e-05
11 95.1311787574 9.15638927551e-06
16 140.277826152 6.20952098301e-06
22 188.945066816 4.6101129795e-06
32 275.671657764 3.15976662965e-06
45 387.071286152 2.25038161213e-06
64 550.492432027 1.58232530415e-06
90 774.640026224 1.12446823744e-06
128 1097.65200754 7.93564899404e-07
181 1422.36034327 6.12403255659e-07
196 1500.92599599 5.80347137214e-07
224 1182.63366931 7.36540931943e-07
256 1311.56362765 6.64137131117e-07

11
plots/scale.plt Normal file
View File

@ -0,0 +1,11 @@
set terminal postscript enhanced
# set nokey
# set log xy
set xlabel "Number of Participating Minions"
set ylabel "Interpolation Throughput"
plot 'scale.out' u 1:2 w lp t 'velocity'\
# ,'' u 1:3 w lp t 'Speedup'