0% found this document useful (0 votes)
9 views35 pages

Mod 5 Image Restoration

The document discusses image restoration, differentiating it from image enhancement, and emphasizes its objective nature in recovering degraded images. It outlines various types of image degradation, such as additive noise and image blur, and introduces models for understanding these processes. Additionally, it covers different noise models and restoration techniques, including inverse filtering, Wiener filtering, and constrained least squares filtering.

Uploaded by

fire.smoke.yolo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views35 pages

Mod 5 Image Restoration

The document discusses image restoration, differentiating it from image enhancement, and emphasizes its objective nature in recovering degraded images. It outlines various types of image degradation, such as additive noise and image blur, and introduces models for understanding these processes. Additionally, it covers different noise models and restoration techniques, including inverse filtering, Wiener filtering, and constrained least squares filtering.

Uploaded by

fire.smoke.yolo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 35

Digital Image Processing

Image Restoration
Image Restoration

•Image restoration vs. image enhancement


• Enhancement:
• largely a subjective process
• Priori knowledge about the degradation is not a must (sometimes
no degradation is involved)
• Procedures are heuristic and take advantage of the psychophysical
aspects of human visual system
• Restoration:
• more an objective process
• Images are degraded
• Tries to recover the images by using the knowledge about the
degradation
Image Restoration

Image restoration concerns the removal or reduction of


degradations which have occurred during the acquisition of the
image. Such degradations may include noise, which are errors in the
pixel values, or optical effects such as out of focus blurring, or
blurring due to camera motion. We shall see that some restoration
techniques can be performed very successfully using
neighbourhood operations, while others require the use of
frequency domain processes. Image restoration remains one of the
most important areas of image processing, but in this chapter the
emphasis will be on the techniques for dealing with restoration,
rather than with the degradations themselves, or the properties of
electronic equipment which give rise to image degradation.
An Image Degradation Model
• Two types of degradation
• Additive noise
• Spatial domain restoration (denoising) techniques are preferred
• Image blur
• Frequency domain methods are preferred
• We model the degradation process by a degradation function h(x,y), an
additive noise term, (x,y), as g(x,y)=h(x,y)*f(x,y)+ (x,y)

• f(x,y) is the (input) image free from any degradation


• g(x,y) is the degraded image
• * is the convolution operator
• The goal is to obtain an estimate of f(x,y) according to the knowledge about the
degradation function h and the additive noise 
• In frequency domain: G(u,v)=H(u,v)F(u,v)+N(u,v)
• Three cases are

• g(x,y)=f(x,y)+ (x,y)
• g(x,y)=h(x,y)*f(x,y)
• g(x,y)=h(x,y)*f(x,y)+ (x,y)
A Model of the Image
Degradation/Restoration Process
A Model of the Image
Degradation/Restoration Process
Noise
Noise Model

•We first consider the degradation due to noise only


• h is an impulse for now ( H is a constant)
•White noise
• Autocorrelation function is an impulse function multiplied by a
constant N −1 M −1
• a ( x, y ) =   ( s, t )  ( s − x, t − y ) = N 0 ( x, y )
t =0 s =0

• It means there is no correlation between any two pixels in the noise


image
• There is no way to predict the next noise value
• The spectrum of the autocorrelation function is a constant (white)
Gaussian Noise

•Noise (image) can be classified according the distribution of


the values of pixels (of the noise image) or its (normalized)
histogram
•Gaussian noise is characterized by two parameters,  (mean)
and σ2 (variance), by

1 −( z −  ) 2 / 2 2
p( z ) = e
2 
•70% values of z fall in the range [(-σ),(+σ)]
•95% values of z fall in the range [(-2σ),(+2σ)]
Gaussian Noise
Gaussian Noise
Gaussian Noise

H.R. Pourreza
Other Noise Models
•Rayleigh noise
2
 ( z − a )e − ( z − a ) / b for z  a
2

p( z ) =  b
0 for z  a

• The mean and variance of this density are


given by b( 4 −  )
 = a + b / 4 and  2 =
4
• a and b can be obtained through mean and
variance
Other Noise Models
•Erlang (Gamma) noise
 a b z b −1 − az
 e for z  0
p ( z ) =  (b − 1)!
0 for z  0

• The mean and variance of this


density are given by
b
 = b / a and  2 =
a2
• a and b can be obtained through
mean and variance
Other Noise Models

•Exponential noise
ae − az for z  0
p( z ) = 
• 0 for z  0
• The mean and variance of
this density are given by

• Special case pf Erlang PDF


with b=1
1
 = 1 / a and  = 2 2

a
Other Noise Models
•Uniform noise
 1
 if a  z  b
• p ( z ) =  b−a
 0 otherwise
• The mean and variance of this
density are given by

(b − a ) 2
 = (a + b) / 2 and  2 =
12
Other Noise Models
•Impulse (salt-and-pepper) noise

 Pa for z = a

p( z ) =  Pb for z = b
0 otherwise

• If either Pa or Pb is zero, the


impulse noise is called unipolar
• a and b usually are extreme values
because impulse corruption is
usually large compared with the
strength of the image signal
• It is the only type of noise that can
be distinguished from others
visually
Salt-and-pepper Noise
Salt-and-pepper Noise
A Sample Image
Effect of Adding Noise to Sample Image
Effect of Adding Noise to Sample Image
Inverse Filtering
The simplest approach to restoration is direct inverse
filtering:
ˆ G (u, v) Even if we know the
F (u, v) = degradation function, we
H (u, v)
cannot recover the un-
N (u, v) degraded image
ˆ
F (u, v) = F (u, v) +
H (u, v)

If the degradation has zero or very small values, then the ratio
N/H could easily dominate our estimation of F .

One approach to get around the zero or small-value problem


is to limit the filter frequencies to value near the origin.
Minimum Mean Square Error Filtering
(Wiener Filtering)
This approach incorporate both the degradation
function and statistical characteristic of noise into the
restoration process.
Image and noise
are random
process

e 2 = E[( f − fˆ ) 2 ]

The objective is to find an estimation for f such that minimized e2


 H * (u , v ) S (u , v ) 
Fˆ (u , v) =  G (u, v)
f

 S f (u , v) H (u, v) + S (u, v) 
2

 H * (u , v) 
= G (u, v)
 H (u , v) + S (u , v) / S f (u, v) 
2

 1 H (u, v)
2

= G (u, v)
 H (u , v) H (u , v) + S (u , v) / S f (u , v) 
2
Constrained Least Squares Filtering

 Vector-matrix form
g ( x , y ) = h ( x , y ) * f ( x , y ) +  ( x, y )

⚫ g = Hf + η

⚫ g , f , η : MN 1
⚫ H : MN  MN
 Minimize

 
M −1 N −1
C =   f ( x, y) 2 2

x =0 y =0

⚫ Subject to
2
ˆ
g − Hf = η
2
 The solution
 H * (u , v ) 
Fˆ (u, v) =  G(u, v)
 H (u, v) +  P(u, v) 
2 2

⚫ Where P (u , v ) is the Fourier transform


of the function
 0 −1 0 
P( x, y ) = − 1 4 − 1
 0 − 1 0 
 Computing  by iteration

r = g − Hfˆ
⚫ Adjust  so that
r = η a
2 2
⚫ Computation
M −1 N −1
r =  r 2 ( x, y)
2

x =0 y =0
M −1 N −1
1
m =
MN
 ( x, y)
x =0 y =0

  ( x, y) − m 
M −1 N −1 2
1
 =
2

MN x =0 y =0

η = MN [ 2 + m2 ]
2
⚫ Algorithm
⚫ 1: Specify an initial value of
⚫ 2: Compute
3: Stop if r = η  a is satisfied;
2 2

otherwise return to Step 2 after
increasing  if r  η − a or
2 2

decreasing  r  η +. a
2 2
⚫ if

You might also like