# How to perform local Fourier Transform of an image?

Consider an image (img) as

A nice explanation of the Fourier transform of an image can be found here. However, I want to perform the Fourier transform locally. For example,

{w,h} = ImageDimensions[img];
imgparts = ImagePartition[img,{w/8,h/8}];


This will give me 64 image parts and I can apply Fourier transform on each image part and assemble them. However, this is computationally very expensive.

Is there any better and faster way (maybe applying the Fourier transform only once) to do it?

• Is what you're trying to do not just some variation of wavelet analysis? reference.wolfram.com/language/guide/Wavelets.html – Sjoerd Smit Apr 12 '18 at 15:20
• @SjoerdSmit In some sense. But I think, there are some fundamental differences. See this paper: ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=958567 – Majis Apr 12 '18 at 15:30
• Well, your partitioning of the image is pretty much equivalent to multiplying the image with 64 different masks. Multiplying in real space = convolution in Fourier space, so what you could do is compute the FT of the image and then perform convolutions of this FT with the FTs of the masks (which should be very simple). – Sjoerd Smit Apr 12 '18 at 15:39
• Furthermore: Map[ImagePeriodogram, imgparts, {2}] and dat = Map[Fourier@*ImageData, imgparts, {2}]; evaluates really fast for me on your example. How many transforms do you plan to do? I don't really see how this is operation is computationally prohibitive. – Sjoerd Smit Apr 12 '18 at 15:57
• @SjoerdSmit Thanks. You are right. – Majis Apr 12 '18 at 16:04