[Scipy-svn] r6972 - trunk/scipy/interpolate
scipy-svn at scipy.org
scipy-svn at scipy.org
Sun Nov 28 18:26:29 EST 2010
Author: ptvirtan
Date: 2010-11-28 17:26:29 -0600 (Sun, 28 Nov 2010)
New Revision: 6972
Modified:
trunk/scipy/interpolate/fitpack.py
Log:
BUG: interpolate: fix an implicit cast to integers in bisplrep causing a warning
Modified: trunk/scipy/interpolate/fitpack.py
===================================================================
--- trunk/scipy/interpolate/fitpack.py 2010-11-28 23:08:19 UTC (rev 6971)
+++ trunk/scipy/interpolate/fitpack.py 2010-11-28 23:26:29 UTC (rev 6972)
@@ -848,8 +848,8 @@
raise TypeError('Given degree of the spline (kx,ky=%d,%d) is not supported. (1<=k<=5)' % (kx,ky))
if m<(kx+1)*(ky+1):
raise TypeError('m >= (kx+1)(ky+1) must hold')
- if nxest is None: nxest=kx+sqrt(m/2)
- if nyest is None: nyest=ky+sqrt(m/2)
+ if nxest is None: nxest=int(kx+sqrt(m/2))
+ if nyest is None: nyest=int(ky+sqrt(m/2))
nxest,nyest=max(nxest,2*kx+3),max(nyest,2*ky+3)
if task>=0 and s==0:
nxest=int(kx+sqrt(3*m))
More information about the Scipy-svn
mailing list