Module 3
Module 3
MODULE 3
Image Restoration
Digital Image Processing
MODULE 3
RBT Level:-
• Restoration: Noise models, L1, L2, L3 in the
Restoration
Presence of Noise Only using Spatial Filtering
and Frequency Domain Filtering, Linear,
Position Invariant Degradations, Estimating
the Degradation Function, Inverse Filtering,
Minimum Mean Square Error (Wiener)
Filtering, Constrained Least Squares Filtering.
[Text: Chapter 5: Sections 5.2, to 5.9]
Digital Image Processing
Image Restoration - 1
Outline
• General approaches
– Inverse filters
– Wiener filters
Digital Image Processing
Image Restoration - 1
Image enhancement vs. restoration
• De-noising
– Spatial filtering
– Frequency domain filtering
Digital Image Processing
Image Restoration - 1
Noise models – examples
Digital Image Processing
Image Restoration - 1
Noise models – periodic noise
Digital Image Processing
De-noising
Image Restoration
5.3 RESTORATION IN THE PRESENCE OF NOISE ONLY ------
SPATIAL FILTERING
• De-noising
– Spatial filtering ( for additive noise)
• Mean filters
• Order-statistics filters
• Adaptive filters
– Frequency domain filtering (for periodic noise)
Image Restoration
Digital Image Processing
Image Restoration - 1
De-noising – Salt & Pepper noise example
Digital Image Processing
Image Restoration - 1
De-noising – Periodic noise example
Digital Image Processing
Image Restoration - 1
De-noising – evaluation
• PSNR
S
M N 2
1
MSE
'
MN i 1 j 1
ij S ij
255 2
PSNR 10 log 10
MSE
• Visual perception
Digital Image Processing
Image Restoration - 1
De-noising – evaluation example
Digital Image Processing
Image Restoration
Degradation models: linear vs. non-linear
5.3 RESTORATION IN THE PRESENCE OF NOISE ONLY ------
FREQUENCY FILTERING
NOTCH FILTERS
Digital Image Processing
NOTCH FILTERS
Digital Image Processing
Image Restoration
5.5 Linear, space-invariant degradations
f ( x, y ) f ( , ) ( x , y )dd
g ( x, y ) H f ( x, y ) ( x, y )
H f ( , ) ( x , y )dd ( x, y)
H f ( , ) ( x , y )dd ( x, y )
Linearity, additivity -->
f ( , ) H ( x , y )dd ( x, y )
f ( , )h( x, , y, )dd ( x, y )
Linearity, homogeneity -->
f ( , )h( x , y )dd ( x, y )
Space-invariant -->
(convolution integral)
Digital Image Processing
Image Restoration
Linear, space-invariant degradations (cont’)
Gs (u, v )
H s ( u, v )
Fˆs (u, v )
Digital Image Processing
Image Restoration
5.6 Estimating degradation function - 2
• Estimation by experimentation
– Point spread function (PSF) G (u, v )
H (u, v )
• Used in optics A
• The impulse becomes a point of light
• The impulse response is commonly referred to as the
PSF
Digital Image Processing
Image Restoration - 1
Estimating degradation function - 3
k ( u 2 v 2 )5 / 6
H (u, v) e
Digital Image Processing
Image Restoration - 1
Estimating degradation function - 3
• Classical approaches
– Inverse filter
– Weiner filter
• Algebraic approaches
• The regularization theory
Digital Image Processing
Image Restoration
5.7 Inverse filtering
• Degradation model
g ( x, y) f ( x, y) h( x, y) ( x, y)
G(u, v) F (u, v) H (u, v) N (u, v)
• Inverse filter
G (u , v) N (u , v)
ˆ
F (u , v)
H (u , v) H (u , v)
N (u , v)
F (u , v)
H (u , v)
Digital Image Processing
Image Restoration - 1
Inverse filtering - examples
k ( u 2 v 2 )5 / 6
H (u, v) e
Digital Image Processing
Image Restoration
5.8 MMSE / Wiener filtering
• In most images, adjacent pixels are highly correlated, while the gray
level of widely separated pixels are only loosely correlated.
• Therefore, the autocorrelation function of typical images generally
decreases away from the origin.
• Power spectrum of an image is the Fourier transform of its
autocorrelation function, therefore we can argue that the power
spectrum of an image generally decreases with frequency.
• Typical noise sources have either a flat power spectrum or one that
decreases with frequency more slowly than typical image power
spectrum.
• Therefore, the expected situation is for the signal to dominate the
spectrum at low frequencies, while the noise dominates the high
frequencies.
Digital Image Processing
Image Restoration - 1
Wiener filtering (cont’)
• Degradation model
g ( x, y) f ( x, y) h( x, y) ( x, y)
G(u, v) F (u, v) H (u, v) N (u, v)
• Wiener filter 2
1 H (u, v)
Fˆ (u, v) G (u, v)
H (u, v) H (u, v) Pn (u, v) / Pf (u, v)
2
2
1 H (u, v)
G (u, v)
H (u, v) H (u, v) K
2
Digital Image Processing
Image Restoration - 1
Wiener filtering - example
Digital Image Processing
Image Restoration - 1
Wiener filtering - example
T
H (u, v)
(ua vb)
sin (ua vb)e j (ua vb )
Digital Image Processing
Image Restoration - 1
Wiener filtering - problems
Image Restoration
5.9 Constrained Least Squares Filtering
min C [
x 0 y 0
2
f ( x, y )]
subject to g Hf η
2 2
Image Restoration - 1
Constrained Least Squares Filtering
The solution
H * (u, v)
Fˆ (u, v) G(u, v)
H (u, v) P(u, v)
2
0 1 0
p( x, y ) 1 4 1
0 1 0
Digital Image Processing
Image Restoration - 1
Constrained Least Squares Filtering - example
Digital Image Processing
All Images taken from Gonzalez & Woods, Digital Image Processing (2002)