Upload
others
View
5
Download
0
Embed Size (px)
Citation preview
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Degradation Model
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Different Noises
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Test Pattern
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Noise Corrupted Test Pattern
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Noise Corrupted Test Pattern (Cont’d)
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Sine Noise Corrupted Image
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Noise Corrupted Strip Image
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
N i d ti ti l filt iNoise reduction – spatial filtering
1 fi
),(),(),( yxyxfyxg ),(),(),( vuNvuFvuG 1 Mean filters
Arithmetic mean filter
xySts
tsgmn
yxf),(
),(1),(ˆ
Geometric mean filtermn
Sts sy
tsgyxf
1
),(
),(),(ˆ
Harmonic mean filter
St tsg
mnyxf
)( )(1),(ˆ
xySts tsg),( ),(
Contraharmonic mean filter
xySts
Qtsgyxf ),(
1),()(ˆ
© 1992–2008 R. C. Gonzalez & R. E. Woods
xySts
Qtsgyxf
),(),(
),(
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
2 Order statistic filters2 Order-statistic filters
Median filter ),(),(ˆ),(
tsgmedianyxfxySts
Max and min filter ),(max),(ˆ),(
tsgyxfxySts
ˆ ),(min),(ˆ),(
tsgyxfxySts
1Midpoint filter
),(min),(max
21),(ˆ
),(),(tsgtsgyxf
xyxy StsSts
Alpha-trimmed filter
xySts
r tsgdmn
yxf),(
),(1),(ˆ
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
3 Adaptive filters3 Adaptive filtersLocal noise reduction filter
Ad ti di filt
LL
myxgyxgyxf ),(),(),(ˆ2
2
Adaptive median filter
Stage A: A1=zmed-zminA2=zmed-zmaxA2 zmed zmaxIf A1>0 and A2<0, go to stage BElse increase the window sizeIf window size < S repeat stage AIf window size < Smax, repeat stage AElse output zmed
Stage B: B1=zxy-zminB2=zxy-zmaxIf B1>0 and B2<0, output zxy
© 1992–2008 R. C. Gonzalez & R. E. Woods
, p xyElse output zmed
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Arithmetic and Geometric Filtering
GuassianGuassian noise added
© 1992–2008 R. C. Gonzalez & R. E. Woods
3X3 Averaging Geometric mean filtering
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Contraharmonic Filtering
(a) Pepper noise (b) Salt noise
© 1992–2008 R. C. Gonzalez & R. E. Woods
Q=1.5 Q=-1.5
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Wrong Selection of Parameter
Q=1.5 Q=-1.5
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
O d S i i Fil iOrder Statistic Filtering
(a) Pepper & salt noise
(b) 3X3 Median
© 1992–2008 R. C. Gonzalez & R. E. Woods
2nd Median Filtering 3rd Median Filtering
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Results of Max & Min Filtering
3X3 Max filtering 3X3 Min filtering
Filtering of pepper noise corrupted image
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
il i d i i il iMean Filtering & Order Statistic Filtering
U if lUniform noise Uniform + salt & pepper noise
5X5 Arithmetic Geometric mean5X5 Arithmetic
Median filtering Trimmed mean filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
filtering
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Fil i f G i N i i h 0Filtering of Gaussian Noise with m=0
Gaussian noise added Arithmetic mean filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Geometric mean filtering Adaptive median filtering
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Median and Adapti e Median Filtering
Salt & pepper t d Median filtering Adaptive
di fil i
Median and Adaptive Median Filtering
corrupted Median filtering median filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Frequency Selective Filters
Ideal bandstop filter
Butterworth bandstop filter
Gaussian bandstop filter
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Removal of Sine Noise
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Sine Noise Image
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Notch Filters
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
N t h Filt iNotch Filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Filtering process:
)} ,,({),(1
yxgFvuG
),()],(1{[),( 1 vuGvuHFyx N R
),(),(),(),(ˆ yxyxwyxgyxf
ba 2
2 ˆˆ1
To determine w(x,y), consider
btas
yxftysxfba
yx2 ),(),()12)(12(
1),(
Where is average of in the neighborhood)(f̂)(f̂
ba
tysxfyxf ),(ˆ1),(ˆ
Where is average of in the neighborhood.),( yxf),( yxf
© 1992–2008 R. C. Gonzalez & R. E. Woods
btas
yfba
yf ),()12)(12(
),(
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
2
2
2
])()()([
)],(),(),([
)12)(12(1),(
b
bt
a
asyxyxwyxg
tysxtysxwtysxg
bayx
]),(),(),([ yxyxwyxg
),(),(thatAssume yxwtysxw
),(),(),(),( yxyxwyxyxw 2
)([ tysxg2
)],(),(),([
)],(),(),([
)12)(12(1),(
b
bt
a
asyxyxwyxg
tysxyxwtysxg
bayx
)]()()([ yyyg
By setting 0),(),(2
yxwyx
)()()()(
we obtain
© 1992–2008 R. C. Gonzalez & R. E. Woods
),(),(
),(),(),(),(),( 22 yxyx
yxyxgyxyxgyxw
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Modeled by PSF
)( vuG G )(
Estimation degradation function
),(ˆ),(),(
vuFvuGvuH
s
ss
AvuGvuH ),(),(
6/522 )()( vukH
© 1992–2008 R. C. Gonzalez & R. E. Woods
)(),( vukevuH
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Air Turbulence Model
K=0.0025
© 1992–2008 R. C. Gonzalez & R. E. Woods
K=0.001 K=0.00025
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Motion Blur Model
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
T
dttyytxxfyxg 00 )](),([),(
Motion blurring model
0
)](),([),( )(200
0
dtdxdyetyytxxfvuG vyuxjT
),(),(),(0
)]()([2
0
00 vuFvuHdtevuFT
tvytuxj
T
dtevuHT
tvytuxj 0
)]()([2 00),(
Further assuming linear motion in both and y directions:Further assuming linear motion in both and y directions:TbttyTattx /)(/)( 00
)( bjT
© 1992–2008 R. C. Gonzalez & R. E. Woods
)()](sin[)(
),( vbuajevbuavbua
TvuH
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Inverse filtering
),(),(ˆ vuNvuG),(),(
),(),(),(
),(vuH
vuFvuH
vuF
For exampleFor example
6/522 ])2/()2/[(),( NvMukevuH ),( evuH
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Inverse FilteringInverse Filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
ˆWiener (MMSE) filtering 22 )ˆ( ffEe
),(),(),(),(),(
),(ˆ2
*
2
*
vuGvuHvuGvuSvuH
vuF f
)(),(1
),(),(/),(),(
),(),(),(),(
),(
2
22
vuGvuH
vuSvuSvuHvuSvuHvuS ff
),(),(/),(),(),( 2 vuG
vuSvuSvuHvuHf
1 1
21 1
2 )(ˆ)(M NM N
fF
1 1
2
0 0
2
1 12
0 0
)],(ˆ),([
),(
),(
),(
M Nu v
M Nu v
yxfyxf
yxf
vuN
vuFSNR
0 00 0 x yu v
)(),(1)(ˆ
2
vuGvuH
vuF
1 1
2)](ˆ)([1 M N
yxfyxfMSE
© 1992–2008 R. C. Gonzalez & R. E. Woods
),(),(),(
),( 2 vuGKvuHvuH
vuF
0 0
)],(),([x y
yxfyxfMN
MSE
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Inverse and Wiener Filtering
Full inverse filtering Radially limited filtering Wiener filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Motion Blur and Additive Noise
Corrupted image
Inverse and Wiener filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Constrained LS Filtering
ηHfg Degraded image in matrix form:
Minimize
1
0
1
0
22 ),(M
x
N
yyxfC
Subject to 22ˆ ηfH-g
)(ˆ* vuH
),(),(),(
),(),( 22 vuGvuPvuH
vuHvuF
where P(u v) is FT ofwhere P(u,v) is FT of
010141
010),( yxp
© 1992–2008 R. C. Gonzalez & R. E. Woods
010
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Constrained LS Filtering
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Constrained LS Filtering with iteration of
Using correct noise parameters
Using wrong noise parameters
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Projection, back projection, and superimpose
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Reconstruction using back projections
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Reconstruction using different projections
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Reconstruction using back projections
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
dxdyyxyxfg jkkkj )sincos(),(),(
dxdyyxyxfg )sincos(),(),(
1 1M N
© 1992–2008 R. C. Gonzalez & R. E. Woods
1
0
1
0)sincos(),(),(),(
M
x
N
ykj yxyxfgg
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
222
otherwise 0
x),(
222 ryAyxf
dyyfdxdyxyxfg
),( )(),(),(
rr
2222
dyAdyyfgrr
2222
),(),(
r 2)()(
22 rAgg
otherwise 0)(),( gg
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
),(),( dyxfyxf 0
),(),( yfyf
)()( ff
0
),(),( yxfyxf
),ysing(xcos),(),( kkk kgyxfk
© 1992–2008 R. C. Gonzalez & R. E. Woods
),sincos(),( yxgyxf
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
Reconstruction of back projected image using sinogramsReconstruction of back-projected image using sinograms
j 2
degG j 2),(),(
dxdydeyxyxfG j2)sincos(),(),(
FT of projection:
dxdyeyxf yxj )sincos(2),(
)()( FG
© 1992–2008 R. C. Gonzalez & R. E. Woods
)sincos(
),(),( sin;cos
wFvuFG vu
~ Fourier slice
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
R t ti i ll l b filt d b k j tiReconstruction using parallel-beam filtered backprojection
)(
dudvevuFyxf vyuxj )(2),(),(
2
)sincos(2)()( ddGf yxj
© 1992–2008 R. C. Gonzalez & R. E. Woods
0 0
)sincos(2),(),( ddeGyxf yxj
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
0
)sincos(2),(),( ddeGyxf yxj
ddeGyxf
yx
j
sincos0
2),(),(
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
T t l t b k j t d iTo get complete, back-projected image:
1) Compute 1-D FT of each projection2) Multiply each FT by the filter function which has
already multiplied by a suitable window3) Obtain the inverse 1-D FT of each resulting filtered
||
3) Obtain the inverse 1 D FT of each resulting filtered transform
4) Integrate (sum) all the 1-D inverse transforms from step 3)step 3).
Frequency-domain windowing function:
1)-(M0
12cos)1(
)(
Mcc
h
© 1992–2008 R. C. Gonzalez & R. E. Woods
otherwise 0
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
R t ti i f b filt d b k j tiReconstruction using fan-beam filtered backprojection
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
sinD
ddfT
2
)i()(1)( ddyxsgyxfT 0
)sincos(),(21),(
sinsincoscossincos rryx)cos(
sinsincoscossincos
r
rryx
ddrsgyxfT
T
2
0
)cos(),(21),(
DgrfDT
DT
),sin(21),(
2 )/(sin
)/(sin
1
1
© 1992–2008 R. C. Gonzalez & R. E. Woods
ddDDrsDT
cossin)cos()/(sin
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction m1 2
ddDDrsprfm
cossin)cos(),(21),(
)sin(sin)cos( ' RDr )()(
ddDRsprfm
cos)'sin(),(21),(
2
m
)()sin
()sin( 2
sR
Rs
dhqR
rfm
m
)'(),(1),(2
02
)(sin2
1)(2
sh
cos),(),( Dpq
),sin(),(),( Dggp
)(i)( D If
© 1992–2008 R. C. Gonzalez & R. E. Woods
)(,sin),( nmnDgmnp If
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods
Chapter 5: Image Restoration and ReconstructionChapter 5: Image Restoration and Reconstruction
© 1992–2008 R. C. Gonzalez & R. E. Woods