[Numpy-discussion] better error message possible?

Thouis (Ray) Jones thouis@gmail....
Thu Jun 7 03:30:33 CDT 2012


I've opened a PR at https://github.com/numpy/numpy/pull/296 for discussion.

A typical result

>>> np.zeros((3,3))[[1,2,3]]
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
IndexError: index 3 is out of bounds for axis 0: [-3,3)

Ray Jones


More information about the NumPy-Discussion mailing list