thouis / numpy-trac-migration

numpy Trac to github issues migration
2 stars 3 forks source link

Library for padding arrays (Trac #655) #4458

Open numpy-gitbot opened 11 years ago

numpy-gitbot commented 11 years ago

Original ticket http://projects.scipy.org/numpy/ticket/655 on 2008-02-11 by trac user timcera, assigned to atmention:stefanv.

The attached pad module contains a group of functions to pad values onto the edges of an n-dimensional array. I use it for FFT analysis in TAPPy (http://tappy.sf.net) to have some hope of reasonable values all the way to the edge of the array. I thought it might be useful.

numpy-gitbot commented 11 years ago

Attachment added by trac user timcera on 2008-02-11: pad.tar.gz

numpy-gitbot commented 11 years ago

Milestone changed to 1.1 by atmention:stefanv on 2008-04-09

numpy-gitbot commented 11 years ago

trac user peridot wrote on 2008-04-09

The patch is actually a more-or-less self-contained python package. The best thing to do is probably to drop it in as numpy.pad (particularly as it has functions like numpy.pad.maximum). It includes tests and documentation (albeit not exaclty in numpy standard format) so it's really a packaging issue.

The package makes it easy to pad vectors on one end or the other with an arbitrary number of values, with wrapped or reflected values, or mean/median/maximum/minimum values of the whole array or part of it.

numpy-gitbot commented 11 years ago

trac user timcera wrote on 2008-08-22

Replying to [comment:2 peridot]:

The patch is actually a more-or-less self-contained python package. The best thing to do is probably to drop it in as numpy.pad (particularly as it has functions like numpy.pad.maximum). It includes tests and documentation (albeit not exaclty in numpy standard format) so it's really a packaging issue.

Thank you for looking at 'pad'. I followed the scipy/numpy standards (as near as I could make them out) from the time that I first started programming 'pad' with the intent of it being a drop in module. I can update to the latest standards if that would ease addition to numpy.

The package makes it easy to pad vectors on one end or the other with an arbitrary number of values, with wrapped or reflected values, or mean/median/maximum/minimum values of the whole array or part of it.

Actually, more than vectors, it can pad N-dimensional arrays. It is useful for any FFT (1 or 2D), plus any convolution or digital filter.

numpy-gitbot commented 11 years ago

Attachment added by trac user timcera on 2008-09-04: pad-0.2.1.tar.gz

numpy-gitbot commented 11 years ago

trac user timcera wrote on 2008-09-04

Just uploaded new version.

Now updated to new Numpy tests and improved documentation. I also changed the names of functions from, for example, 'maximum' to 'with_maximum'. The changed names I thought would clarify from other function names in Numpy.

numpy-gitbot commented 11 years ago

atmention:cournape wrote on 2009-03-02

Stefan, I think you were interested in this, if you could take a look. If you don't have time, just put it to unscheduled,

numpy-gitbot commented 11 years ago

Milestone changed to 1.4.0 by atmention:cournape on 2009-03-09

numpy-gitbot commented 11 years ago

Milestone changed to Unscheduled by atmention:rgommers on 2011-03-30