[SciPy-Dev] bug in min(max)imum_filter1d

Jaime Fernández del Río jaime.frio at gmail.com
Fri Sep 5 16:17:09 EDT 2014


A while back I made some changes to ndimage.filters.min(max)imum_filter1d
that sped it up quite considerably, see here:

https://github.com/scipy/scipy/pull/3517

A little after that, I started a discussion on whether a different
algorithm, about 30% slower for random inputs, but up to 10x faster for
worse case inputs, would be a better option, and submitted a new PR, see
here:

http://mail.scipy.org/pipermail/scipy-dev/2014-April/019776.html
https://github.com/scipy/scipy/pull/3527

I didn't follow up on that discussion, and so #3527 had been lingering
abandoned ever since.

Recently, Julian Taylor discovered that #3517 breaks the scikit-image
tests, because it does not handle properly the case with a filter of size
1, see here:

https://github.com/scipy/scipy/issues/3898

Rather than fixing the existing code merged in #3517, I have reworked the
code in #3527 a little, because it had the same trouble with filters of
size 1, and updated it. Merging the latest version of #3527 will fix the
skimage bug, but I would like to bring up the discussion on whether this is
the right thing to do or not. I certainly prefer #3527 to #3517, but if
there is no consensus I will close #3527 and fix #3517 instead.

Thanks,

Jaime

-- 
(\__/)
( O.o)
( > <) Este es Conejo. Copia a Conejo en tu firma y ayúdale en sus planes
de dominación mundial.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/scipy-dev/attachments/20140905/0dd84d1e/attachment.html>


More information about the SciPy-Dev mailing list