IPPR Lecture6-1
IPPR Lecture6-1
Recognition (IPPR):
(Lecture 6)
x 0 y 0
DFT
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
60
123
DFT & Images
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
61
123
DFT & Images
62
of
123
DFT & Images (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
DFT
of
63
123
DFT & Images (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
64
123
DFT & Images (cont…)
65
of
123
The Inverse DFT
It is really important to note that the Fourier
transform is completely reversible
The inverse DFT is given by:
M 1N1
1
f ( x, y )
MN
F (u, v)e
u 0 v 0
j 2 ( ux / M vy / N )
of
67
123
The DFT and Image Processing
68
of
123
Some Basic Frequency Domain Filters
of
69
123
Some Basic Frequency Domain Filters
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
70
123
Some Basic Frequency Domain Filters
71
of
123
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) 2 (v N / 2) 2 ]1/ 2
74
of
123
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
75
123
Ideal Low Pass Filter (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
76
123
Ideal Low Pass Filter (cont…)
77
of
123
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
78
of
123
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
79
of
123
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
80
of Chapter 4
123
Image Enhancement in the
Frequency Domain
81
of
123
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
83
of
123
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
84
of
123
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
89
of
123
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
90
123
Lowpass Filtering Examples
91
of
123
Lowpass Filtering Examples (cont…)
Different lowpass Gaussian filters used to
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
92
123
Lowpass Filtering Examples (cont…)
93
of
123
Lowpass Filtering Examples (cont…)
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Spectrum of Processed
original image image
94
of
123
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
96
of
123
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
98
of
123
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
100
of
123
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
102
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Butterworth
high pass filtering of order
2 with D0 = 15
103
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Gaussian
high pass filtering with
D0 = 15
104
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of ideal
high pass filtering
with D0 = 15
106
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Butterworth
high pass filtering of order
2 with D0 = 15
107
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
Results of Gaussian
high pass filtering with
D0 = 15
108
of Chapter 4
123
Image Enhancement in the
Frequency Domain
109
of Chapter 4
123
Image Enhancement in the
Frequency Domain
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
123
110
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
123
111
Highpass Filter Comparison
112
of
123
Highpass Filter Comparison
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
123
High frequency 113
emphasis result Original image
of
123
118
Laplacian In The Frequency Domain
119
of
123
Laplacian In The Frequency Domain
Images taken from Gonzalez & Woods, Digital Image Processing (2002)
of
123
Inverse DFT of 120
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
121
of
123
Frequency Domain Laplacian Example
Original Laplacian
image filtered
image
Laplacian
Enhanced
image scaled
image
122
of
123
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!
123
of
Frequency Domain Filtering & Spatial
123 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