Frequency Domain FIltering.pdf

2,559 views 43 slides Nov 09, 2022
Slide 1
Slide 1 of 43
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43

About This Presentation

Frequency Domain


Slide Content

ImageAnalysisandProcessing Image Enhancements
in the Frequency Domain
LaurentNajman
[email protected]
ESIEEParis
Universit´eParis-Est,Laboratoired’InformatiqueGaspard-Monge,´Equipe
A3SI
imageprocessing,transforms–p.1/46

Book
Chapter4(pages147–219)
DigitalImageProcessing,SecondEdition
authors:RafaelC.GonzalezandRichardE.Woods editor:PrenticeHall
–p.3/44

FrequencyDomainFilteringOperation
Frequencydomain:spacedenedbyvaluesoftheFouriertransformandits
frequencyvariables(u;v).
RelationbetweenFourierDomainandimage:
u=v=0correspondstothegray-levelaverage Lowfrequencies:image'scomponentwithsmoothgray-levelvariation(e.g.
areaswithlowvariance)
Highfrequencies:quickgray-levelchange(e.g.edges,noise)
Source:http://www.imageprocessingbook.com–p.4/44

FilteringintheFrequencyDomain
Let
H(u;v)
alter,alsocalledltertransferfunction.
Filter:suppresscertainfrequencieswhileleaving
othersunchanged
G(u;v)=H(u;v)F(u;v)
H(u;v)
inimageprocessing:
Ingeneral
H(u;v)
isreal:zero-phase-shiftlter
H
multiplyrealandimaginarypartsof
F
(u;v)=tan
1I(u;v)
R(u;v)
doesnotchangeif
H
isreal
–p.5/44

GeneralStepsforFiltering
1.Multiplyinputimageby
(1)
x+y
(centering)
2.Compute
F(u;v)
(DFT)
3.Multiply
F(u;v)
by
H(u;v)
(ltering)
4.ComputeinverseDFTof
H(u;v)F(u;v)
5.Obtaintherealpartoftheresult
6.Mutliplyby
(1)
x+y
(decentering)
–p.6/44

FromSpatialtoFrequencyDomain
f(x;y)h(x;y),F(u;v)H(u;v)
(x;y)h(x;y),F[(u;v)]H(u;v)
h(x;y),H(u;v)
Multiplicationinthefrequencydomainisaconvolution
inthespatialdomain.
Given
h(x;y)
,wecanobtain
H(u;v)
bytakingthe
inverseFouriertransform.
–p.7/44

Padding(1)
convolution:
f(x)h(x)=
1
M
M1X m=0
f(m)h(xm)
periodicity:
F(u;v)=F(u+M;v)=F(u;v+N)=F(u+M;v+N)
–p.8/44

Padding(2)
Source:http://www.imageprocessingbook.com–p.9/44

Padding(3)
Let
P
anidenticalperiodfor
f
and
g
:
f
e
(x)=
(
f(x)0xA1
0AxP
g
e
(x)=
(
g(x)0xB1
0BxP If
P<A+B1
,thetwosignalwilloverlap:
wraparounderror.
If
P>A+B1
,theperiodswillbeseparated.
If
P=A+B1
,theperiodswillbeadjacent.
Wecanavoidwraparounderrorusing
PA+B1
.
Ingeneral,weuse
P=A+B1
.
–p.10/44

Padding(4)
Source:http://www.imageprocessingbook.com–p.11/44

Padding(5)
Source:http://www.imageprocessingbook.com–p.12/44

Padding:Example
Source:http://www.imageprocessingbook.com–p.13/44

SpatialRepresentationofaFilter
1.Multiplylter
H(u;v)
by
(1)
u+v
(centering)
2.ComputetheinverseDFT
3.MultiplytherealpartoftheinverseDFTby
(1)
x+y
Source:http://www.imageprocessingbook.com–p.14/44

ASimpleFilter:NotchFilter(1)
Wewishtoforcetheaveragevalueofanimageto
zero:
F(0;0)
istheaveragevalueoftheimage
ifsizeoftheimageis
MN
thenthecentered
valueoftheFouriertransformistheaveragevalue
(
M
2
,
N2
) H(u;v)=
(
0if(u;v)=(
M
2
;
N2
)
1otherwise:
–p.15/44

ASimpleFilter:NotchFilter(2) notchlter(constantfunctionwithaholeattheorigin)
H(u;v)=
(
0if(u;v)=(
M
2
;
N2
)
1otherwise:
Source:http://www.imageprocessingbook.com–p.16/44

LowpassandHighpassFilter
Source:http://www.imageprocessingbook.com–p.17/44

SmoothingFrequency-DomainFilters
G(u;v)=H(u;v)F(u;v)
Smoothing:attenuatingspeciedrangeof
high-frequencycomponents
Threetypesoflowpasslter:
ideal(verysharp) Butterworth(tunable) Gaussian(verysmooth)
–p.18/44

IdealLowpassFilters(1)
H(u;v)=
(
1ifD(u;v)D
0
0ifD(u;v)>D
0
D
0
:nonnegativequantity
D(u;v)
:distancefromapoint
(u;v)
totheorigin
origin:
(
M
2
;
N2
)
(centered)
Then,
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
–p.19/44

IdealLowpassFilters(2)
ideallter(ILPF):allfrequenciesinsideacircleof
radius
D
0
arepassedwithnoattenuation
Inourcase:
zero-phase-shiftlter radiallysymmetric
Transition:cutofffrequency Ringingbehaviorofthelter
Source:http://www.imageprocessingbook.com–p.20/44

IdealLowpassFilters:Example
Source:http://www.imageprocessingbook.com–p.21/44

CutoffFrequency
Computecirclesthatenclosespecicamountoftotal
imagepower
P
T P
T
=
M1X u=0
N1
X v=0
P(u;v)
P(u;v)=jF(u;v)j
2
=R
2
(u;v)+I
2
(u;v)
=
100
P
T
X
u
X
v
P(u;v)
Source:http://www.imageprocessingbook.com–p.22/44

RingingEffectofILPF
Source:http://www.imageprocessingbook.com–p.23/44

ButterworthLowpassFilters
BLPFoforder
n
,withacutofffrequencydistance
D
0
is
denedas
H(u;v)=
1
1+[
D(u;v)
D
0
]
2n
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
noclearcutoffbetweenpassedandltered
frequencies
–p.24/44

ButterworthLowpassFilters(2)
Source:http://www.imageprocessingbook.com–p.25/44

ButterworthLowpassFilters:Example
n=2
,radii=
5;15;30;80;230
Source:http://www.imageprocessingbook.com–p.26/44

RingingEffectofBLPF
Source:http://www.imageprocessingbook.com–p.27/44

GaussianLowpassFilters(1)
TheformofagaussianlowpasslterGLPFin2Dis:
H(u;v)=e
D
2
(u;v)
2
2
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
TheinverseFouriertransformofaGLPFisalsoa
Gaussian
AspatialGaussianlterwillhavenoringing
–p.28/44

GaussianLowpassFilters(2)

:mesureofthespreadoftheGaussiancurve
Let
=D
0
,then:
H(u;v)=e
D
2
(u;v)
2D
2
0
Source:http://www.imageprocessingbook.com–p.29/44

GaussianLowpassFilters:Example(1)
n=2
,radii=
5;15;30;80;230
Source:http://www.imageprocessingbook.com–p.30/44

GaussianLowpassFilters:Example(2)
Source:http://www.imageprocessingbook.com–p.31/44

HighpassFilters(1)
Highpasslter:imagesharpening(low-frequency
attenuation)
Inourcase:
zero-phase-shiftlter radiallysymmetric
H
hp
(u;v)=1H
lp
(u;v)
with:
H
lp
(u;v)
:transferfunctionofthecorresponding
lowpasslter
H
hp
(u;v)
:transferfunctionofthecorresponding
highpasslter
–p.32/44

HighpassFilters(2)
Source:http://www.imageprocessingbook.com–p.33/44

IdealHighpassFilters(1)
H(u;v)=
(
0ifD(u;v)D
0
1ifD(u;v)>D
0
D
0
:nonnegativequantity
D(u;v)
:distancefromapoint
(u;v)
totheorigin
origin:
(
M
2
;
N2
)
(centered)
Then,
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
–p.34/44

IdealLowpassFilters:example
Source:http://www.imageprocessingbook.com–p.35/44

ButterworthHighpassFilters
BLPFoforder
n
,withacutofffrequencydistance
D
0
is
denedas
H(u;v)=
1
1+[
D
0
D(u;v)
]
2n
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
noclearcutoffbetweenpassedandltered
frequencies
–p.36/44

ButterworthHighpassFilters:Example
Source:http://www.imageprocessingbook.com–p.37/44

GaussianHighpassFilters
TheformofagaussianlowpasslterGLPFin2Dis:
H(u;v)=1e
D
2
(u;v)
2D
2
0
D(u;v)=
r
(u
M
2
)
2
+(v
N
2
)
2
TheinverseFouriertransformofaGLPFisalsoa
Gaussian
AspatialGaussianlterwillhavenoringing
–p.38/44

GaussianHighpassFilters:Example
Source:http://www.imageprocessingbook.com–p.39/44

Laplacian:SpatialDomain(1) r
2
f=
@
2
f
@x
2
+
@
2
f
@y
2
@
2
f
@x
2
=f(x+1;y)+f(x1;y)2f(x;y)
@
2
f
@y
2
=f(x;y+1)+f(x;y1)2f(x;y)
r
2
f=f(x+1;y)+f(x1;y)+f(x;y+1)
+f(x;y1)4f(x;y)
Source:http://www.imageprocessingbook.com–p.40/44

Laplacian:SpatialDomain(2)
g(x;y)=
(
f(x;y)r
2
f(x;y)ifthecentercoecientisnegative
f(x;y)+r
2
f(x;y)ifthecentercoecientispositive
Source:http://www.imageprocessingbook.com–p.41/44

Laplacian:FrequencyDomain(1)
F

d
n
f(x)
dx
n

=(ju)
n
F(u)
Then,
F
h
@
2
f(x;y)
@x
2
+
@
2
f(x;y) @y
2
i
=(ju)
2
F(u;v)+(jv)
2
F(u;v)
=(u
2
+v
2
)F(u;v)
Finally,
F[r
2
f(x;y)]=(u
2
+v
2
)F(u;v)
TheLaplacianlterinthefrequencydomainis:
H(u;v)=(u
2
+v
2
)
–p.42/44

Laplacian:FrequencyDomain(2)
–p.43/44

Laplacian:Example
–p.44/44
Tags