%pylab inline
Populating the interactive namespace from numpy and matplotlib
font = {'family' : 'normal',
'size' : 16}
matplotlib.rc('font', **font)
hpc = numpy.loadtxt('numa/hpc.txt')
aws = numpy.loadtxt('numa/aws.txt')
x = hpc[:,0] / (1e9/4.0)
plot(x, hpc[:,1] / 60, 'b-', label='total time')
plot(x, hpc[:,1] / 60, 'r.')
plot(x, hpc[:,2] / 60, 'b--', label='post allocation only')
plot(x, hpc[:,2] / 60, 'r*')
print x
axis(ymin=0)
xlabel('Memory size (GB)')
ylabel('Time (m) to do same task')
#axis(ymax=3600)
legend(loc='upper left')
savefig('/tmp/fig4.pdf')
[ 4.00000000e-02 8.00000000e-02 1.20000000e-01 1.60000000e-01 2.00000000e-01 2.40000000e-01 2.80000000e-01 3.20000000e-01 3.60000000e-01 4.00000000e-01 8.00000000e-01 1.20000000e+00 1.60000000e+00 2.00000000e+00 2.40000000e+00 2.80000000e+00 3.20000000e+00 3.60000000e+00 4.00000000e+00 8.00000000e+00 1.20000000e+01 1.60000000e+01 2.00000000e+01 2.40000000e+01 2.80000000e+01 3.20000000e+01 3.60000000e+01 4.00000000e+01 4.00000000e+02 9.76000000e+02]
x = hpc[:,0] / (1e9/4.0)
plot(x, hpc[:,1] / hpc[0,1], 'b-', label='total time')
plot(x, hpc[:,1] / hpc[0,1], 'r.')
plot(x, hpc[:,2] / hpc[0,2], 'b--', label='post allocation only')
plot(x, hpc[:,2] / hpc[0,2], 'r*')
print x
axis(ymin=0)
xlabel('Memory size (GB)')
ylabel('Lost time r due only to RAM acc')
#axis(ymax=40)
legend(loc='upper left')
savefig('/tmp/fig4b.pdf')
[ 4.00000000e-02 8.00000000e-02 1.20000000e-01 1.60000000e-01 2.00000000e-01 2.40000000e-01 2.80000000e-01 3.20000000e-01 3.60000000e-01 4.00000000e-01 8.00000000e-01 1.20000000e+00 1.60000000e+00 2.00000000e+00 2.40000000e+00 2.80000000e+00 3.20000000e+00 3.60000000e+00 4.00000000e+00 8.00000000e+00 1.20000000e+01 1.60000000e+01 2.00000000e+01 2.40000000e+01 2.80000000e+01 3.20000000e+01 3.60000000e+01 4.00000000e+01 4.00000000e+02 9.76000000e+02]
x = aws[:,0] / (1e9/4.0)
plot(x, aws[:,1], 'b-')
plot(x, aws[:,1], 'r.')
axis(ymin=0)
xlabel('Memory allocation (GB)')
ylabel('Time (s) to do standard task')
savefig('/tmp/fig3.pdf')