Lec - 11 SIP CIS-322 Freq Domain Processing
Lec - 11 SIP CIS-322 Freq Domain Processing
Lecture No. 11
Filtering
in the Frequency Domain
CIS-322
Basic Properties
Rate of change at 900
• Value of transform at (u,v)=(0,0):
1 M 1N 1
F(0,0) f (x, y)
MN x 0 y 0
which means that the value of FT at the origin = the
average gray level of the image
• FT is also conjugate symmetric:
F(u,v)=F*(-u,-v)
so |F(u,v)|=|F(-u,-v)|
which means that the FT spectrum is symmetric.
The separation of spectrum zeros in the u-direction is exactly
twice the separation of zeros in the v-direction.
1
Image Enhancement in the Frequency Domain
Some basic properties of the
frequency domain
• F(0,0) corresponds to the average gray level
of the image
• As we move away from the origin of the
transform , the low frequency correspond to
the slowly varying components of the image.
• As we move further away from the origin,
the higher frequencies begin to correspond
to faster and faster gray level of the image.
by
f ( x, y )(1) x y F (u M / 2, v N / 2)
2
Enhancement in
the Frequency Domain
• Types of enhancement that can be done:
– Lowpass filtering: reduce the high-frequency
content -- blurring or smoothing
(Low frequencies in the Fourier Transform are
responsible for the general gray level appearance
of an image over smooth areas)
– Highpass filtering: increase the magnitude of
high-frequency components relative to low-
frequency components -- sharpening.
(High frequencies are responsible for detail, such
as edges and noise.) Image d is sharpe with little smooth gray level as F(0,0)= 0
3
Image Enhancement in the
Frequency Domain
Ideal Filter (Lowpass)
• Ideal:
4
ILPF
The most simple lowpass filter is the ideal lowpass. It suppresses all
A dominant frequencies higher than the cut-off frequency Do and leaves smaller
component at the
origin and frequencies unchanged
concentric circular
components about The drawback of this filter function is a ringing effect that occurs
the central
component.
along the edges of the filtered spatial domain image. This
No. of circles is phenomenon is illustrated in Figure 1, which shows the shape of the
inversely prop. to one-dimensional filter in both the frequency and spatial domains for
cutoff freq.
two different values of Do . We obtain the shape of the two-
dimensional filter by rotating these functions about the y-axis. As
mentioned earlier, multiplication in the Fourier domain corresponds
to a convolution in the spatial domain. Due to the multiple peaks of
the ideal filter in the spatial domain, the filtered image produces
ringing along intensity edges in the spatial domain.
ILPF ILPF
Better results can be achieved with a Gaussian shaped filter
function. The advantage is that the Gaussian has the same shape
in the spatial and Fourier domains and therefore does not incur
the ringing effect in the spatial domain of the filtered image. A
commonly used discrete approximation to the Gaussian is the
Butterworth filter. Applying this filter in the frequency domain
shows a similar result to the Gaussian smoothing in the spatial
domain. One difference is that the computational cost of the
spatial filter increases with the standard deviation (i.e. with the
size of the filter kernel), whereas the costs for a frequency filter
are independent of the filter function. Hence, the spatial Gaussian
filter is more appropriate for narrow lowpass filters, while the
Butterworth filter is a better implementation for wide lowpass
filters.
5
Image Enhancement in the
Frequency Domain
Butterworth Filter (Lowpass)
• To define a cutoff frequency locus: at points
for which H(u,v) is down to a certain fraction
of its maximum value.
6
Image Enhancement in the
Frequency Domain
7
Ideal Filter (Highpass) Butterworth Filter (Highpass)
0 if D(u , v) D0 H (u , v)
1
H (u , v)
1 if D(u , v) D0 1 [ D0 / D(u , v)]2 n
8
9