[Numpy-discussion] Numpy large array bug

Kashyap Ashwin Ashwin.Kashyap@thomson....
Mon Sep 21 15:28:58 CDT 2009

Also, what about PyArray_PutMask()

That function also has a line like "int i, chunk, ni, max_item, nv,

Should that be changed as well?

(Your patch does not fix my original issue.)


BTW, in numpy 1.3, that is present in numpy/core/src/multiarraymodule.c.

Can someone please give me a temporary patch to test? I am not familiar
with numpy codebase!





I can confirm this bug for the last svn.



>>> a.put([2*1024*1024*1024 + 100,], 8)

IndexError: index out of range for array


in this case, I think the error is that in


in PyArray_PutTo line 209 should be:

    intp i, chunk, ni, max_item, nv, tmp;

instead of:

    int i, chunk, ni, max_item, nv, tmp;


fixing it as suggested:

>>> a.put([2*1024*1024*1024 + 100,], 8)

>>> a.max()




-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20090921/6d22d282/attachment.html 

More information about the NumPy-Discussion mailing list