# Interpret numpy.fft.fft2 output

My goal is to obtain a plot with the spatial frequencies of an image - kind of like doing a fourier transformation on it. I don't care about the position on the image of features with the frequency f (for instance); I'd just like to have a graphic which tells me how much of every frequency I have (the amplitude for a frequency band could be represented by the sum of contrasts with that frequency).

I am trying to do this via the numpy.fft.fft2 function.

Here is a link to a minimal example portraying my use case.

As it turns out I only get distinctly larger values for frequencies[:30,:30], and of these the absolute highest value is frequencies[0,0]. How can I interpret this?

• What exactly does the amplitude of each value stand for?
• What does it mean that my highest value is in frequency[0,0] What is a 0 Hz frequency?
• Can I bin the values somehow so that my frequency spectrum is orientation agnostic?

• so practically the frequency a coefficient at freq[0,x] corresponds to is len(freq[0,:])/x and the same for y? what about coefficients outside freq[0,x] and freq[y,0]? I understand these are for "diagonal waves" - but how does np.fft.fft2 decide if a spatial wave is diagonal or if it's just a horizontal and vertical wave co-occurring? Jan 26 '14 at 15:56