[Numpy-discussion] A faster median (Wirth's method)
Charles R Harris
Thu Sep 3 08:34:29 CDT 2009
On Thu, Sep 3, 2009 at 12:14 AM, Sturla Molden <email@example.com> wrote:
> Chad Netzer skrev:
> > That's right, Robert. Basically, I meant doing a median on a square
> > (or rectangle) "view" of an array, without first having to ravel(),
> > thus generally saving a copy. But actually, since my selection based
> > median overwrites the source array, it may not save a copy anyway.
> Avoiding copies of timy buffers is futile optimization.
> QuickSelect is overkill for tiny buffers like common filter kernels.
> Insertion sort is fine.
Shell sort is nice for sizes in the awkward range.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion