I\'ve got a numpy script that spends about 50% of its runtime in the following code:
numpy
s = numpy.dot(v1, v1)
where
v1 = v[1
Only thing I can think of to accelerate this is to make sure your NumPy installation is compiled against an optimized BLAS library (like ATLAS). numpy.dot() is one of only a few NumPy functions that make use of BLAS.
numpy.dot()