[Numpy-discussion] fast way to convolve a 2d array with 1d filter

frank wang f.yw at hotmail.com
Mon Dec 1 20:38:11 EST 2008


Hi,
 
I need to convolve a 1d filter with 8 coefficients with a 2d array of the shape (6,7). I can use convolve to perform the operation for each row. This will involve a for loop with a counter 6. I wonder there is 
an fast way to do this in numpy without using for loop. Does anyone know how to do it?
 
Thanks
 
Frank
_________________________________________________________________
Access your email online and on the go with Windows Live Hotmail.
http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_access_112008
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20081201/9aa59f6a/attachment.html>


More information about the NumPy-Discussion mailing list