Python 3.x Integer Division in pypulse.utils.subdivide
Closed this issue · 1 comments
tycohen commented
~/.local/lib/python3.7/site-packages/pypulse/utils.py in subdivide(tdata, ydata, noise, rms, minsep, maxsep, fac)
481 # Test new knot at the midpoint
482 half = N/2
--> 483 tdataL = tdata[:half]
484 tdataR = tdata[half:]
485 ydataL = ydata[:half]
TypeError: slice indices must be integers or None or have an __index__ method
I think this could be fixed with half = N//2
mtlam commented
Completed by PR#14 .