I can reproduce your error using cython 0.22 , and I think this error is related to this thread in cython-users .
It seems that cython gets into the problem when calculating 10**-9 . If you use 10**-9.0 instead, everything will be fine.
Please note that you can get rid of this error and discard a piece of code by replacing 5.0*10**(-9) with 5e-9 .
However, this seems like a bug in cython, not in your code base.
source share