[Numpy-discussion] Numpy large array bug

Citi, Luca lciti at essex.ac.uk
Mon Sep 21 15:23:14 EDT 2009


I can confirm this bug for the last svn.

Also:
>>> 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
numpy/core/src/multiarray/item_selection.c
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()
8




More information about the NumPy-Discussion mailing list