[Numpy-discussion] index objects are not broadcastable to a single shape
oliphant at ee.byu.edu
Wed Apr 12 18:30:03 CDT 2006
Simon Burton wrote:
>This must be up there with the most useless confusing error messages:
>Traceback (most recent call last):
> File "<stdin>", line 1, in ?
>ValueError: index objects are not broadcastable to a single shape
The problem with these error messages is that some code is used in a
wide-variety of circumstances. The original error message was conceived
in thinking about the application of the code to one circumstance while
this particular error is occurring in a different one.
The standard behavior is to just propagate the error up. Better error
messages means catching a lot more errors and special-casing error
messages. It can be done, but it's tedious work.
More information about the Numpy-discussion