[Numpy-discussion] Sum, multiply are slow ?

David Cournapeau david@ar.media.kyoto-u.ac...
Thu Jul 12 03:51:28 CDT 2007


Keith Goodman wrote:
> On 7/12/07, David Cournapeau <david@ar.media.kyoto-u.ac.jp> wrote:
>   
>> While profiling some code, I noticed that sum in numpy is kind of
>> slow once you use axis argument:
>>     
>
> Here is a related thread:
> http://projects.scipy.org/pipermail/numpy-discussion/2007-February/025903.html
>   
Thanks, I remembered there was something about that a few months ago, 
could not find it. By quickly looking at the code for PyArray_Sum, this 
looks like it has nothing to do with caching or looping, but the way 
that summing is implemented (generic reduce).

David


More information about the Numpy-discussion mailing list