Professional Documents
Culture Documents
Unit II - FrequencyFiltering - Enhancement in FD
Unit II - FrequencyFiltering - Enhancement in FD
Image Enhancement:
Filtering in the Frequency Domain
DFT
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
9
of
54
DFT & Images
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
10
DFT & Images
11
of
54
DFT & Images (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
DFT
of
54
12
DFT & Images (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
13
DFT & Images (cont…)
14
of
54
The Inverse DFT
It is really important to note that the Fourier
transform is completely reversible
The inverse DFT is given by:
M 1 N 1
1
f ( x, y )
MN
F (u, v)e
u 0 v 0
j 2 ( ux / M vy / N )
of
54
17
Some Basic Frequency Domain Filters
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
18
Some Basic Frequency Domain Filters
19
of
54
Smoothing Frequency Domain Filters
1 if D(u , v) D0
H (u , v)
0 if D (u , v) D0
where D(u,v) is given as:
D(u , v) [(u M / 2) (v N / 2) ]
2 2 1/ 2
22
of
54
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
23
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
24
Ideal Low Pass Filter (cont…)
25
of
54
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Result of filtering
Original with ideal low pass
image filter of radius 5
Result of filtering
Result of filtering
with ideal low pass
with ideal low pass
filter of radius 230
filter of radius 80
26
of
54
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Result of filtering
with ideal low pass
filter of radius 5
27
of
54
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Result of filtering
with ideal low pass
filter of radius 15
28
of
54
Butterworth Lowpass Filters
The transfer function of a Butterworth lowpass
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Result of filtering
Original with Butterworth filter
image of order 2 and cutoff
radius 5
Result of filtering
Result of filtering with
with Butterworth filter
Butterworth filter of
of order 2 and cutoff
order 2 and cutoff
radius 230
radius 80
30
of
54
Butterworth Lowpass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Original
image
Result of filtering
with Butterworth filter
of order 2 and cutoff
radius 5
31
of
54
Butterworth Lowpass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Result of filtering
Original with Gaussian filter
image with cutoff radius 5
Result of filtering
Result of filtering
with Butterworth
with ideal low pass
filter of order 2
filter of radius 15
and cutoff radius
15
Result of filtering
with Gaussian
filter with cutoff
radius 15
35
of
54
Lowpass Filtering Examples
A low pass Gaussian filter is used to connect
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
broken text
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
36
Lowpass Filtering Examples
37
of
54
Lowpass Filtering Examples (cont…)
Different lowpass Gaussian filters used to
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
38
Lowpass Filtering Examples (cont…)
39
of
54
Lowpass Filtering Examples (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Spectrum of Processed
original image image
40
of
54
Sharpening in the Frequency Domain
0 if D (u , v) D0
H (u , v)
1 if D (u , v) D0
where D0 is the cut off distance as before
42
of
54
Ideal High Pass Filters (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
1
H (u , v)
1 [ D0 / D(u , v)]2 n
where n is the order and D0 is the cut off
distance as before
44
of
54
Butterworth High Pass Filters (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Results of
Butterworth Butterworth
high pass high pass
filtering of filtering of
order 2 with order 2 with
D0 = 15 D0 = 80
D 2 ( u ,v ) / 2 D0 2
H (u , v) 1 e
where D0 is the cut off distance as before
46
of
54
Gaussian High Pass Filters (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Results of
Gaussian Gaussian
high pass high pass
filtering with filtering with
D0 = 15 D0 = 80
Results of ideal
high pass filtering
with D0 = 15
48
of
54
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Butterworth
high pass filtering of order
2 with D0 = 15
49
of
54
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Gaussian
high pass filtering with
D0 = 15
50
of
54
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of ideal
high pass filtering
with D0 = 15
52
of
54
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Butterworth
high pass filtering of order
2 with D0 = 15
53
of
54
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Gaussian
high pass filtering with
D0 = 15
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
54
High frequency 54
emphasis result Original image
of
54
Inverse DFT of 59
Laplacian in the Laplacian in the
frequency domain frequency domain
domain
in the frequency
2-D image of Laplacian
spatial filter
left compared to
the image on the
Laplacian In The Frequency Domain
Zoomed section of
60
of
54
Frequency Domain Laplacian Example
Original Laplacian
image filtered
image
Laplacian
Enhanced
image scaled
image
61
of
54
Fast Fourier Transform
The reason that Fourier based techniques have
become so popular is the development of the
Fast Fourier Transform (FFT) algorithm
Allows the Fourier transform to be carried out in
a reasonable amount of time
Reduces the amount of time required to perform
a Fourier transform by a factor of 100 – 600
times!
62
of
Frequency Domain Filtering & Spatial
54 Domain Filtering
Similar jobs can be done in the spatial and
frequency domains
Filtering in the spatial domain can be easier to
understand
Filtering in the frequency domain can be much
faster – especially for large images
63
of
54
Summary
In this lecture we examined image enhancement
in the frequency domain
– The Fourier series & the Fourier transform
– Image Processing in the frequency domain
• Image smoothing
• Image sharpening
– Fast Fourier Transform
64
of
Imteresting Application Of Frequency
54 Domain Filtering
65
of
Imteresting Application Of Frequency
54 Domain Filtering
66
of
54
Questions?