Phase correlation is a frequency domain approach to determine the relative translative movement between two images.
Method
Given two input images a and b:
- Apply a window function (e.g the Hamming window) on both images to reduce edge effects
- Calculate the discrete 2D Fourier transform of both images
- Take the conjugate of the second image
- Multiply the Fourier transforms together elementwise
- Normalize this produce elementwise (yielding a normalized cross power spectrum )
- Inverse transform the normalized cross power spectrum
- Determine peak in inverse transform (possible using sub-pixel methods ).
Mathematical derivation
- (Δx,Δy) = argmaxΔx,Δy{PC}
Proof
The technique is based on the Fourier shift theorem.
- PC = δ(x - Δx,y - Δy)
Example
The following image demonstrates the usage of phase-correlation to determe relative translative movement between two images corrupted by independent gaussian noise. One can clearly see a peak in the phase-correlation spectrum approximately at (30,33).
References
- E. De Castro and C. Morandi "Registration of Translated and Rotated Images Using Finite Fourier Transforms", IEEE Transactions on pattern analysis and machine intelligence, Sept. 1987