On Wed, Dec 12, 2012 at 3:20 PM, Ralf Gommers <[email protected]> wrote:
> For numpy indexing this may not be appropriate though; checking every index
> value used could slow things down and/or be quite disruptive.

For array fancy indices, a dtype check on the entire array would
suffice. For lists and scalars, I doubt it'd be substantial amount of
overhead compared to the overhead that already exists (for lists, I'm
not totally sure whether these are coerced to arrays first -- if they
are, the dtype check need only be performed once after that). At any
rate, a benchmark of any proposed solution is in order.

David
_______________________________________________
NumPy-Discussion mailing list
[email protected]
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to