Re: [Numpy-discussion] Index Array Performance

2012-02-14 Thread Marcel Oliver
Francesc Alted wrote: > On Feb 14, 2012, at 1:50 AM, Wes McKinney wrote: > [clip] > > But: > > > > In [40]: timeit hist[i, j] > > 1 loops, best of 3: 32 us per loop > > > > So that's roughly 7-8x slower than a simple Cython method, so I > > sincerely hope it could be brought down to

[Numpy-discussion] Index Array Performance

2012-02-13 Thread Marcel Oliver
Hi, I have a short piece of code where the use of an index array "feels right", but incurs a severe performance penalty: It's about an order of magnitude slower than all other operations with arrays of that size. It comes up in a piece of code which is doing a large number of "on the fly" histogr