[SciPy-User] ifft on images, symmetry artifacts?

josef.pktd@gmai... josef.pktd@gmai...
Mon Jan 11 19:08:19 CST 2010


On Mon, Jan 11, 2010 at 7:18 PM, Joe Barfett <joebarfett@yahoo.ca> wrote:

> Hello,
> I'm using scipy (numpy.fft.fft2) to transform an image into the frequency
> domain. Then by using numpy.fft.ifft2 to transform the same image back into
> the spatial domain, I find that I get symmetry in the image around a
> reflection line (and not the original image).
> Google has revealed websites like this one:
> http://www.rzuser.uni-heidelberg.de/~ge6/Programing/convolution.html<http://www.rzuser.uni-heidelberg.de/%7Ege6/Programing/convolution.html>
> This is the code snippet they use:
>
> def Convolution(image1,image2):
> 	""" Simple convolution example """
> 	fftimage = fft2(image1)*fft2(image2)
> 	return ifft2(fftimage).real
> #end of Convolution
>
> which uses ifft but generates appropriate output. They do however only use
> the real component of the frequency domain image. I find the exact same
> approach does not work in my case, but rather gives these weird symmetries.
> It's been a few weeks of hacking and I would really appreciate the guidance
> of someone more experienced than me. Thanks a great deal if you know the
> answer!
> joe
>

Something I recently found that might be helpful

http://blogs.mathworks.com/steve/2009/12/04/fourier-transform-visualization-using-windowing/

http://shalin.wordpress.com/2009/12/06/fftifft/

(I know next to nothing about image processing but struggle with fft in
general)

Josef



>
>
> ------------------------------
> The new Internet Explorer® 8 - Faster, safer, easier. Optimized for Yahoo!
> *Get it Now for Free!* <http://downloads.yahoo.com/ca/internetexplorer/>
>
> _______________________________________________
> SciPy-User mailing list
> SciPy-User@scipy.org
> http://mail.scipy.org/mailman/listinfo/scipy-user
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/scipy-user/attachments/20100111/2754fcde/attachment.html 


More information about the SciPy-User mailing list