[SciPy-user] amd64 specific error in fitpack spline interpolation
Stefan van der Walt
stefan at sun.ac.za
Wed Aug 30 11:33:21 EDT 2006
On Wed, Aug 30, 2006 at 10:00:26PM +1200, Angus McMorland wrote:
> Hi all,
>
> I posted about this problem a few months ago, but we didn't get very
> far, but the annoyance level of the problem is enough now for me to have
> another go.
>
> I'm trying to run the spline example from the cookbook (my exact code,
> called spl.py, is inlined below). On an ix86 computer this works fine,
> and returns the expected graphs, but on an amd64 machine I get the error
> below. Both computers are running debian etch, with recent svn numpy and
> scipy.
>
> TypeError: array cannot be safely cast to required type
> > /usr/lib/python2.4/site-packages/scipy/interpolate/fitpack.py(217)splprep()
> 216
> t,c,o=_fitpack._parcur(ravel(transpose(x)),w,u,ub,ue,k,task,ipar,s,t,
> --> 217 nest,wrk,iwrk,per)
> 218 _parcur_cache['u']=o['u']
Hi Angus,
This is fixed in SVN (it works on the AMD Athlon 64 that I have access
to). The C-wrappers expect 32-bit integers, instead of the 64-bit
integers associated with 'int' on your platform.
Can any of the developers tell me what the correct way is of handling
64-bit integers in C, using the numpy API? Or more specifically, of
handling the default system type integer.
Regards
Stéfan
More information about the SciPy-User
mailing list