[Numpy-discussion] choose() broadcasting

Travis E. Oliphant oliphant at enthought.com
Fri Oct 17 17:31:31 EDT 2008


Roman Bertle wrote:
> * Travis E. Oliphant <oliphant at enthought.com> [081003 22:20]:
>   
>> Roman Bertle wrote:
>>     
>>> Hello,
>>>
>>> I have found something I call a bug in the numpy choose() method and
>>> wanted to report it in trac.
>>>   
>>>       
>> Thanks for your report.  I'm not sure why you are having trouble with 
>> Trac, but I've created a ticket for this problem.
>>     
>
> Hello,
>
> trac works for me know. And thank you for fixing the bug, the svn numpy
> version works now for me. But there remains an issue I want to report.
> choose is much slower in numpy than in numarray, and even more if an
> output array is specified, as these tests show:
>   
Thanks for the report.   You should add another ticket for this case.  I 
suspect it might be a result of the extra copies that are done in the 
PyArray_Choose routine because the algorithm assumes contiguous arrays.

It deserves a look.   It probably wouldn't be too difficult to avoid the 
copy.

-Travis




More information about the NumPy-Discussion mailing list