Download presentation
Presentation is loading. Please wait.
1
CS654: Digital Image Analysis
Lecture 20: Image Enhancement in Frequency Domain
2
Recap of Lecture 19 Spatial filtering Mean Filter
Non-Local Mean Filter Median Filter Unsharp Masking Adaptive Unsharp Masking
3
Outline of Lecture 20 Image Enhancement in Frequency Domain
Low Pass Filtering High pass Filtering Butterworth Filtering Gaussian Filtering Homomorphic Filtering
4
Introduction Frequency is the rate of repetition of certain periodic events Variation of image brightness with its position in space Fourier transform is reversible Fourier filtering or Frequency domain filtering Convolution in spatial domain = Multiplication in Frequency domain
5
Frequency domain Enhancement Pipeline
Spatial Domain Frequency Domain Mask/ Filter/ Kernel โ(๐ฅ,๐ฆ) Mask/ Filter/ Kernel H(๐ข,๐ฃ) DFT Output Image G(๐ข,๐ฃ) Multiply Input Image ๐(๐ฅ,๐ฆ) Input Image F(๐ข,๐ฃ) DFT Output Image g(๐ฅ,๐ฆ) IDFT
6
A quick recap of DFT in 2D Forward transformation (DFT) ๐น ๐ข,๐ฃ = ๐ฅ=0 ๐โ1 ๐ฆ=0 ๐โ1 ๐ ๐ฅ,๐ฆ expโก[โ๐2๐ ๐ข๐ฅ ๐ + ๐ฃ๐ฆ ๐ ] ๐(๐ฅ,๐ฆ) is an image of dimension ๐ร๐ 0โค๐ขโค๐โ1,0โค๐ฃโค๐โ1 Inverse transformation (IDFT) ๐ ๐ฅ,๐ฆ = 1 ๐๐ ๐ข=0 ๐โ1 ๐ฃ=0 ๐โ1 ๐น ๐ข,๐ฃ expโก[๐2๐ ๐ข๐ฅ ๐ + ๐ฃ๐ฆ ๐ ] ๐น(๐ข,๐ฃ) is the DFT image 0โค๐ฅโค๐โ1,0โค๐ฆโค๐โ1
7
2-D DFT Forward transformation ๐ฃ ๐,๐ = ๐=0 ๐โ1 ๐=0 ๐โ1 ๐ข ๐,๐ ๐ ๐ ๐๐+๐๐
๐ฃ ๐,๐ = ๐=0 ๐โ1 ๐=0 ๐โ1 ๐ข ๐,๐ ๐ ๐ ๐๐+๐๐ where, 0โค๐,๐โค๐โ1 Forward transformation ๐ข ๐,๐ = ๐=0 ๐โ1 ๐=0 ๐โ1 ๐ฃ ๐,๐ ๐ ๐ โ ๐๐+๐๐ where, 0โค๐,๐โค๐โ1 Reverse transformation where, ๐๐ฅ๐ โ๐2๐ ๐ = ๐ ๐
8
Frequency domain filtering
Filtering in spatial domain is convolution of ๐(๐ฅ,๐ฆ) by the filter kernel โ(๐ฅ,๐ฆ) Filtering in spatial domain = ๐(๐ฅ,๐ฆ)โโ(๐ฅ,๐ฆ) Filtering in frequency domain is the multiplication of the Fourier transform of the image and the filter kernel Filtering in spatial domain = ๐น ๐,๐ ร๐ป(๐,๐) Take a inverse Fourier transform of the resultant image
9
Low pass filtering Non-seperable Seperable
๐ซ ๐ ๐ฃ ๐ข ๐ป ๐ข,๐ฃ = 1, ๐๐๐ ๐ข 2 + ๐ฃ 2 โค ๐ท 0 0, ๐๐กโ๐๐๐ค๐๐ ๐ Seperable ๐ฃ ๐ข ๐ป ๐ข,๐ฃ = 1, ๐๐๐ ๐ขโค ๐ท ๐ ๐๐๐ ๐ฃโค ๐ท ๐ 0, ๐๐กโ๐๐๐ค๐๐ ๐
10
Butterworth filter ๐ป ๐,๐ = 1 1+ ๐ 2 + ๐ 2 ๐ท 0 2๐
Images: Gonzalez & Woods, 3rd edition Butterworth filter Transfer function for 2D Butterworth filter ๐ป ๐,๐ = ๐ 2 + ๐ 2 ๐ท ๐ ๐= order of the Butterworth filter ๐ท 0 = Cut-off frequency
11
High-pass Filters Complementary to LP Filters
Butterworth High-Pass filter ๐ป ๐ข,๐ฃ = 0, ๐ท(๐ข,๐ฃ)โค ๐ท 0 1, ๐๐กโ๐๐๐ค๐๐ ๐ Ideal High Pass Filter (IHPF) ๐ป ๐,๐ = ๐ท ๐ 2 + ๐ ๐ Butterworth High Pass Filter (BHPF)
12
Gaussian Filters (Low-pass, High-pass)
Popular for removing ringing effect Transfer function for 2-D Gaussian LPF (GLPF) Transfer function for 2-D Gaussian HPF (GHPF) ๐ป ๐ข,๐ฃ =๐๐ฅ๐ โ ๐ท 2 (๐ข,๐ฃ) 2 ๐ 2 ๐ป ๐ข,๐ฃ =1โ๐๐ฅ๐ โ ๐ท 2 (๐ข,๐ฃ) 2 ๐ 2
13
Selective filtering Operate on a given range of frequencies
Bandpass, Band reject Band-reject filter
14
Homomorphic Filter ๐ ๐ฅ,๐ฆ = ๐ ๐ ๐ฅ,๐ฆ โ ๐ ๐ (๐ฅ,๐ฆ) ๐ง ๐ฅ,๐ฆ = ln ๐(๐ฅ,๐ฆ)
๐ ๐ฅ,๐ฆ = ๐ ๐ ๐ฅ,๐ฆ โ ๐ ๐ (๐ฅ,๐ฆ) ๐ ๐ ๐ฅ,๐ฆ = Illumination component ๐ ๐ ๐ฅ,๐ฆ = Reflectance component ๐ง ๐ฅ,๐ฆ = ln ๐(๐ฅ,๐ฆ) = ln ๐ ๐ ๐ฅ,๐ฆ + ln ๐ ๐ (๐ฅ,๐ฆ) ๐ ๐ข,๐ฃ = ๐น ๐ ๐ข,๐ฃ + ๐น ๐ (๐ข,๐ฃ) Fourier transformation of input signal Let, ๐ป(๐ข,๐ฃ)= the filer to be applied on ๐ ๐ข,๐ฃ , then ๐ ๐ข,๐ฃ = ๐ป(๐ข,๐ฃ)๐น ๐ ๐ข,๐ฃ + ๐ป(๐ข,๐ฃ)๐น ๐ (๐ข,๐ฃ) Transformed image After Inverse Fourier Transformation ๐ ๐ฅ,๐ฆ = ๐โฒ ๐ ๐ฅ,๐ฆ + ๐ โฒ ๐ ๐ฅ,๐ฆ โ๐ ๐ฅ,๐ฆ = exp ๐ ๐ โฒ ๐ฅ,๐ฆ .expโก[ ๐ ๐ โฒ (๐ฅ,๐ฆ)]
15
Homomorphic Filter Design
Images: Gonzalez & Woods, 3rd edition Homomorphic Filter Design ๐พ ๐ฟ <1; ๐พ ๐ป >1
16
Images: Gonzalez & Woods, 3rd edition
Example
17
Thank you Next Lecture: Image Restoration
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.