In [7]:
import numpy
import pylab
from scipy.interpolate import spline

anni = numpy.arange(2007,2019)
flops32 = numpy.array([384,470,708.5,1344.96,1581.1,3090.43,4499.7,5120.6,6144,10157,12500,14000])/1000
flops64 = numpy.array([0,311,422,550,665.6,1312,1555,2388,(2388+5032)/2,5032,7450,1000])/1000

print(anni.shape,flops32.shape)
xretta = numpy.linspace(2007,2017,1000)


retta = (xretta-2007)*90/1000


flops32 = spline(anni,flops32,xretta)
flops64 = spline(anni,flops64,xretta)

%matplotlib notebook
pylab.figure(figsize=(7, 5))
pylab.plot(xretta,retta,'--',label = "x86 CPU")
pylab.plot(xretta,flops32, label = "float32 GPU")
pylab.plot(xretta,flops64, label = "float64 GPU")
pylab.legend()
pylab.ylabel("TFLOPS", font)
pylab.xlabel("Year")
pylab.title('GPU-CPU FLOPS evolution')
pylab.savefig("/home/protoss/plotto3.pdf", format='pdf')


(12,) (12,)
/home/protoss/.local/lib/python3.6/site-packages/ipykernel_launcher.py:16: DeprecationWarning: `spline` is deprecated!
spline is deprecated in scipy 0.19.0, use Bspline class instead.
  app.launch_new_instance()
/home/protoss/.local/lib/python3.6/site-packages/ipykernel_launcher.py:17: DeprecationWarning: `spline` is deprecated!
spline is deprecated in scipy 0.19.0, use Bspline class instead.

In [ ]: