[Numpy-discussion] searchsorted() and memory cache
Charles R Harris
Thu May 15 14:26:50 CDT 2008
On Wed, May 14, 2008 at 8:50 PM, Andrew Straw <email@example.com> wrote:
> Aha, I've found the problem -- my values were int64 and my keys were
> uint64. Switching to the same data type immediately fixes the issue!
> It's not a memory cache issue at all.
> Perhaps searchsorted() should emit a warning if the keys require
> casting... I can't believe how bad the hit was.
I think it used to fail and that was fixed not so long ago. Was it casting
the keys or was it casting the big sorted array? The latter would certainly
slow things down and would be a bug, and a bug of the sort that might have
slipped in when the casting was added.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Numpy-discussion