IP 04 · Does the sharpest low-pass filter give the best image?
IntermediateIP 04 · Filtering in the Frequency DomainImage lab
Description
Filter a real photo in the frequency domain and compare an ideal, a Butterworth and a Gaussian low-pass at the same cutoff.
Try this: Choose the ideal filter with cutoff 12 and look at the red and blue pixels around the edges. Switch to Gaussian at the same cutoff. Which filter rings, and which has the higher PSNR?
Explanation
Answer the prediction first, or open the explanation when you are ready.
Show the explanation
A sharp cut in frequency is a sinc in space, and a sinc oscillates around every edge, so the ideal filter overshoots. Butterworth softens the cut (its ringing grows with the order n) and the Gaussian is Gaussian in both domains, so it never overshoots. At cutoff 12 the ideal filter pushes about 1.6% of the pixels out of range and the Gaussian none, and the Gaussian also has the higher PSNR.
Lab · IP 04 · Does the sharpest low-pass filter give the best image?
Loading image…
Try this: Choose the ideal filter with cutoff 12 and look at the red and blue pixels around the edges. Switch to Gaussian at the same cutoff. Which filter rings, and which has the higher PSNR?
A real 128 × 128 crop of the camera test image. The transfer function multiplies its 2-D FFT (no padding, so the image is treated as periodic) and the inverse transform is not clipped before ripples are counted. Cutoff D0 is in cycles per image; Gaussian H = exp(−D²/2D0²); Butterworth H = 1/(1 + (D/D0)^2n). Overshoot counts pixels more than 0.02 outside the original image’s own gray range. PSNR compares the filtered image, clipped to [0, 1], with the original.
Method and image sources
- Rafael C. Gonzalez & Richard E. Woods, Digital Image Processing, 4th ed., Pearson, 2018 (frequency-domain filtering)
- scikit-image test images (skimage.data): camera is CC0 by Lav Varshney; coins is from the Brooklyn Museum collection, no known copyright restrictions; astronaut is a NASA photograph in the public domain