[SciPy-dev] ndimage & numpy

Travis Oliphant oliphant.travis at ieee.org
Fri Mar 10 07:15:04 CST 2006


Travis Oliphant wrote:
> Jonathan Taylor wrote:
>   
>> Hi all,
>>
>> I spent some time today trying to get
>>
>>      scipy.sandbox.ndimage
>>
>> working with numpy instead of it requiring numarray (and numpy as 
>> well).....
>>
>>     
>
> Thanks for your work. 
>
> I've taken your work and removed the typecasting (the image processing 
> works with a lot of types).  The type problem was due to the fact that 
> numpy.int32 did not correspond exactly with the c-type PyArray_INT32 
> (which nd_image is checking against).  
>
> Thus, numpy needed fixing to accomodate this use case.  
>
> The fix is in SVN (revision 2214)
>
> I checked in the bulk of your changes to SciPy.    I'm getting 6 errors 
> for the test.py program now.
>
> This is very great news.  As soon as we squash those errors we will move 
> nd_image up to mainstream scipy.
>   


And done.  The remaining errors where due to using complex64 instead of 
complex128

and the small gaussian filter error is due to the fact that .sum() in 
numarray defaults to .sum(dtype='d') even for float32 arrays. 

All tests of nd_image pass for me and I've moved nd_image as a scipy 
package.

This is a great day indeed.  I've wanted this for some time.....


-Travis




More information about the Scipy-dev mailing list