Upload
others
View
1
Download
0
Embed Size (px)
Citation preview
Ioannis Rekleitis
Denoising
ImageDegrada*onandRestora*on
http://fireoracleproductions.com/services__samples
Google image
Image degradation due to • noise in transmission • imperfect image acquisition
• environmental condition • quality of sensor
CSCE 590: Introduction to Image Processing 2 Slides courtesy of Prof. Yan Tong
Proper*esofNoise
• Spatialproperties– Spatiallyperiodicnoise– Spatiallyindependentnoise
• Frequencyproperties– Whitenoise–noisecontainingallfrequencieswithinabandwidth
CSCE 590: Introduction to Image Processing 3 Slides courtesy of Prof. Yan Tong
ImageRestora*onwithAddi*veNoise
),(),(),(),(),(),(vuNvuFvuGyxyxfyxg
+=
+= η
Noisemodels:• Impulsenoise:pepperandsalt• Continuousnoisemodel:
• Gaussian,Rayleigh,Gamma,Exponential,Uniform
CSCE 590: Introduction to Image Processing 4 Slides courtesy of Prof. Yan Tong
ImageRestora*onwithAddi*veNoise
),(),(),(),(),(),(vuNvuFvuGyxyxfyxg
+=
+= η
Noisemodels:• Impulsenoise:pepperandsalt• Continuousnoisemodel:
• Gaussian,Rayleigh,Gamma,Exponential,Uniform
CSCE 590: Introduction to Image Processing 5 Slides courtesy of Prof. Yan Tong
Some Important Noise Model
2
2
2)(
21)( σ
σπ
zz
ezp−
−
=
http://www.gergltd.com/cse486/project2/ • Due to electronic circuit • Due to the image sensor
• poor illumination • high temperature
CSCE 590: Introduction to Image Processing 6 Slides courtesy of Prof. Yan Tong
Some Important Noise Model
⎪⎩
⎪⎨
⎧
<
≥−=
−−
az
azeazbzp
baz
0
)(2)(
2)(
⎪⎩
⎪⎨
⎧
<
≥−=
−−
00
0)!1()(
1
z
zebza
zpaz
bb
Rayleigh noise • range imaging • Background model for Magnetic Resonance Imaging (MRI) images
Gamma noise • laser imaging
CSCE 590: Introduction to Image Processing 7 Slides courtesy of Prof. Yan Tong
Some Important Noise Model
⎪⎪⎩
⎪⎪⎨
⎧
=
=
=
Otherwise0
for for
)(bzPazP
zP b
a
⎩⎨⎧
<
≥=
−
000
)(zzae
zPaz
⎪⎩
⎪⎨⎧ ≤≤−=
otherwise
bzaabzP0
1)(
Exponential noise • laser imaging
Impulse noise • salt and pepper noise • A/D converter error • bit error in transmission
Uniform noise
CSCE 590: Introduction to Image Processing 8 Slides courtesy of Prof. Yan Tong
An Example
What is its histogram?
CSCE 590: Introduction to Image Processing 9 Slides courtesy of Prof. Yan Tong
An Example (cont.)
CSCE 590: Introduction to Image Processing 10 Slides courtesy of Prof. Yan Tong
An Example (cont.)
CSCE 590: Introduction to Image Processing 11 Slides courtesy of Prof. Yan Tong
Estimation of Noise Parameters
Take a small stripe of the background, do statistics for the mean and variance.
CSCE 590: Introduction to Image Processing 12 Slides courtesy of Prof. Yan Tong
Mean Filters for Continuous Noise Models
Arithmetic Mean Filter: a linear filter
∑∈
=xySts
tsgmn
yxf),(
),(1),(ˆ
),( yxxyS
m
n
CSCE 590: Introduction to Image Processing 13 Slides courtesy of Prof. Yan Tong
Non-linear Mean Filters
Geometric Mean Filter
Harmonic Mean Filter
Contraharmonic Mean Filter
CSCE 590: Introduction to Image Processing 14 Slides courtesy of Prof. Yan Tong
Non-linear Mean Filters
Geometric Mean Filter
Harmonic Mean Filter
Contraharmonic Mean Filter
mn
Sts xy
tsgyxf
1
),(
),(),(ˆ⎥⎥⎦
⎤
⎢⎢⎣
⎡= ∏
∈
∑∈
=
xySts tsgmn
yxf
),( ),(11
1),(ˆ
∑
∑
∈
∈
+
=
xy
xy
Sts
QSts
Q
tsg
tsgyxf
),(
),(
1
),(
),(),(ˆ
Workwellfor• Continuousnoise• Saltnoise
Failforthepeppernoise
Qistheorderofthe3ilter• positiveQremovespeppernoise• negativeQremovessaltnoise• Specialcases:Q=0,Q=-1
CSCE 590: Introduction to Image Processing 15 Slides courtesy of Prof. Yan Tong
Mean Filter
Geometric Mean Filter
mn
Sts xy
tsgyxf
1
),(
),(),(ˆ⎥⎥⎦
⎤
⎢⎢⎣
⎡= ∏
∈
• Removingthesaltnoise• Failinthepeppernoise
r a b
CSCE 590: Introduction to Image Processing 16 Slides courtesy of Prof. Yan Tong
An Example
CSCE 590: Introduction to Image Processing 17 Slides courtesy of Prof. Yan Tong
An Example Pepper noise Salt noise
Q=1.5 Q=-1.5
CSCE 590: Introduction to Image Processing 18 Slides courtesy of Prof. Yan Tong
A Failed Case with Wrong Sign of Contraharmonic Filter
CSCE 590: Introduction to Image Processing 19 Slides courtesy of Prof. Yan Tong
Order-Statistic Filters -- Median Filter
Repeating median filter will remove most of the noise while increase image blurring
CSCE 590: Introduction to Image Processing 20 Slides courtesy of Prof. Yan Tong
Order-Statistic Filters -- Max/Min Filters
• Find the extreme points • Remove the targeting impulse noise
CSCE 590: Introduction to Image Processing 21 Slides courtesy of Prof. Yan Tong
Order-Sta*s*cFilters• MidpointLilter– Combineorderstatisticsandaveraging– Worksbestforrandomlydistributednoise,likeGaussianoruniformnoise
– Notsuitableforimpulsenoiseandblurtheboundary
•
⎥⎦⎤
⎢⎣⎡ +=
∈∈)},({min)},({max
21),(ˆ
),(),(tsgtsgyxf
xyxy StsSts
Random noise Salt noise Pepper noise http://www.digimizer.com/manual/m-image-filtermid.php CSCE 590: Introduction to Image Processing 22
Slides courtesy of Prof. Yan Tong
Order-Sta*s*cFilters
• Alpha-trimmedmeanLilter– Deleted/2lowestandd/2highestintensityvalues– AbalancebetweenarithmeticmeanLilterandmedianLilter
– Suitableforcombinedsalt-and-pepperandGaussiannoise
∑∈−
=xyStsr tsg
dmnyxf
),(),(1),(ˆ
CSCE 590: Introduction to Image Processing 23 Slides courtesy of Prof. Yan Tong
Example
CSCE 590: Introduction to Image Processing 24 Slides courtesy of Prof. Yan Tong
Adap*veFilters
• AdaptivelocalnoisereductionLilter• Keyelements:
– theintensityvalue– thevarianceofthenoise– thelocalmeanoftheneighborhood– thelocalvarianceoftheneighborhood
• Properties:
– If,àidealcase
– Ifislow,preservetheedgeinformation
[ ]LL
myxgyxgyxf −−= ),(),(),(ˆ 2
2
σ
ση
),( yxg2ησ
2Lσ
Lm
02 =ησ ),(),(ˆ yxgyxf =
22 / Lσση),(),(ˆ yxgyxf ≈
CSCE 590: Introduction to Image Processing 25 Slides courtesy of Prof. Yan Tong
Examples
CSCE 590: Introduction to Image Processing 26 Slides courtesy of Prof. Yan Tong
Adap*veMedianFilter• StageA:checkifthemedianvalueisanextremevalue
• StageB:checkifthecenterpixelisanextremevalue
med
max
maxmed
minmed
output ElseA stagerepeat size windowIf
size window theincrease ElseB stage togo,02 AND01 If
21
zS
AAzzAzzA
≤
<>
−=
−=
med
max
min
output Else
output ,02 AND01 If
2
1
zzBB
zzBzzB
xy
xy
xy
<>
−=
−=
Goal 1: remove salt-and-pepper noise with higher probability
Goal 2: smoothing the noise other than impulses
Goal 3: reduce distortion
CSCE 590: Introduction to Image Processing 27 Slides courtesy of Prof. Yan Tong
Adaptive Median Filter -- Example
CSCE 590: Introduction to Image Processing 28 Slides courtesy of Prof. Yan Tong
Mean Filter
Harmonic Mean Filter
∑∈
=
xySts tsgmn
yxf
),( ),(11
1),(ˆ
• Removingthesaltnoise• Failinthepeppernoise
CSCE 590: Introduction to Image Processing 29 Slides courtesy of Prof. Yan Tong
Mean Filter
Contraharmonic Mean Filter
∑
∑
∈
∈
+
=
xy
xy
Sts
QSts
Q
tsg
tsgyxf
),(
),(
1
),(
),(),(ˆ
Qistheorderofthe3ilter• positiveQremovespeppernoise• negativeQremovessaltnoise• Specialcases:Q=0,Q=-1
CSCE 590: Introduction to Image Processing 30 Slides courtesy of Prof. Yan Tong
Periodical Noise
Image is corrupted by a set of sinusoidal noise of different frequencies
CSCE 590: Introduction to Image Processing 31 Slides courtesy of Prof. Yan Tong
Es*matetheDegrada*onFunc*on
• Observation• Experimentation• Mathematicalmodeling
CSCE 590: Introduction to Image Processing 32 Slides courtesy of Prof. Yan Tong
Estimate Degradation Function - Observation
Assumptions:
• The degradation function is linear and position-invariant
• No other knowledge about the degradation function
Estimation by image observation:
• Extract a subimage with strong signal
• Perform restoration on the subimage
),(ˆ),(),(vuFvuGvuH
s
ss =
Observed subimage
Restored subimage
degradation function in the subimage
),( vuHApplication: restoring old pictures
Higher signal-to-noise ratio
CSCE 590: Introduction to Image Processing 33 Slides courtesy of Prof. Yan Tong
Estimate Degradation Function - Experimentation
Assumptions: • A similar equipment is available
• Change the system setting can achieve similar degraded images
AvuGvuH ),(),( =
Observed image
Impulse signal
CSCE 590: Introduction to Image Processing 34 Slides courtesy of Prof. Yan Tong
Estimation by Modeling
6/522 )(),( vukevuH +−=
Modeling the atmospheric turbulence
CSCE 590: Introduction to Image Processing 35 Slides courtesy of Prof. Yan Tong
Estimation by Modeling – Motion Blur
Constantvelocityalongxandydirection:
Tattx /)(0 = Tbtty /)(0 =
CSCE 590: Introduction to Image Processing 36 Slides courtesy of Prof. Yan Tong
Estimation by Modeling – Cont.
∫ −−=T
dttyytxxfyxg0 00 )](),([),(
An example of motion blur
Motion in both x and y direction during acquisition
CSCE 590: Introduction to Image Processing 37 Slides courtesy of Prof. Yan Tong
Estimation by Modeling – Cont.
∫ +−=T tvytuxj dtevuH0
)]()([2 00),( π
An example of motion blur
∫ +−=T tvytuxj dtevuFvuG0
)]()([2 00),(),( π
CSCE 590: Introduction to Image Processing 38 Slides courtesy of Prof. Yan Tong
Estimation by Modeling – Example
)(
)()](sin[),( vbuaje
vbuavbuaTvuH +−
+
+= π
ππ
Constant velocity along x and y direction:
Tattx /)(0 = Tbtty /)(0 =
WhatisH(u,v)?
CSCE 590: Introduction to Image Processing 39 Slides courtesy of Prof. Yan Tong
Ques*ons?
CSCE 590: Introduction to Image Processing 40