0% found this document useful (0 votes)
70 views32 pages

Digital Image Processing: Image Restoration: Noise Removal

Image restoration techniques aim to remove noise from degraded images and restore the original image quality. Common types of noise include Gaussian, salt and pepper, and periodic noise. Noise can be removed using spatial domain filters like mean, median, and order statistics filters or frequency domain filters for periodic noise. The median filter is effective for salt and pepper noise while band reject filters in the frequency domain target specific frequencies to remove periodic noise.

Uploaded by

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

Digital Image Processing: Image Restoration: Noise Removal

Image restoration techniques aim to remove noise from degraded images and restore the original image quality. Common types of noise include Gaussian, salt and pepper, and periodic noise. Noise can be removed using spatial domain filters like mean, median, and order statistics filters or frequency domain filters for periodic noise. The median filter is effective for salt and pepper noise while band reject filters in the frequency domain target specific frequencies to remove periodic noise.

Uploaded by

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

Digital Image Processing

Image Restoration:
Noise Removal
Contents
In this lecture we will look at image
restoration techniques used for noise removal
– What is image restoration?
– Noise and images
– Noise models
– Noise removal using spatial domain filtering
– Periodic noise
– Noise removal using frequency domain filtering
What is Image Restoration?
Image restoration attempts to restore
images that have been degraded
– Identify the degradation process and attempt
to reverse it
– Similar to image enhancement, but more
objective
Reasons for Noises

These noises are appeared on images in


different ways:

at the time of acquisition due to noisy


sensors,
due to faulty scanner or faulty digital
camera,
due to transmission channel errors,
due to corrupted storage media.
What is Noise?
 The prime factor that reduces the quality
of the image is Noise.
 Noise hides the important details of
images.
 To enhance the image qualities, we have
to remove noises from the images without
loss of any image information.
 Noise removal is one of the pre-
processing stages of image processing.
Noise Model
We can consider a noisy image to be
modelled as follows:
g ( x, y )  f ( x, y )   ( x, y )
where f(x, y) is the original image pixel,
η(x, y) is the noise term and g(x, y) is the
resulting noisy pixel
If we can estimate the model the noise in an
image is based on this will help us to figure
out how to restore the image
Noise Models
There are many different Gaussian Rayleigh
models for the image
noise term η(x, y):
– Gaussian
• Most common model Erlang Exponential

– Rayleigh
– Erlang
– Exponential
Uniform
– Uniform Impulse

– Impulse
• Salt and pepper noise
Noise Example
The test pattern to the right is
ideal for demonstrating the
addition of noise
The following slides will show
the result of adding noise Image
based on various models to
this image
Histogram to go here

Histogram
Noise Example (cont…)

Gaussian Rayleigh Erlang


Noise Example (cont…)

Histogram to go here

Exponential Uniform Impulse


Filtering to Remove Noise
We can use spatial filters of different kinds to
remove different kinds of noise
The arithmetic mean filter is a very simple
one and is calculated as follows:
ˆf ( x, y )  1
 g ( s, t )
mn ( s ,t )S xy
1
/9 /9
1
/9
1 This is implemented as the
simple smoothing filter
1
/9 /9
1
/9
1

Blurs the image to remove


1
/9 /9
1
/9
1
noise
Other Means
There are different kinds of mean filters all of
which exhibit slightly different behaviour:
– Geometric Mean
– Harmonic Mean
– Contraharmonic Mean
Other Means (cont…)
There are other variants on the mean which
can give different performance
Geometric Mean:
1
  mn
fˆ ( x, y )    g ( s, t )
( s ,t )S xy 
Achieves similar smoothing to the arithmetic
mean, but tends to lose less image detail
Other Means (cont…)
Harmonic Mean:
mn
fˆ ( x, y ) 
1

( s ,t )S xy g ( s, t )
Works well for salt noise, but fails for pepper
noise
Also does well for other kinds of noise such
as Gaussian noise
Other Means (cont…)
Contraharmonic Mean:
 g ( s, t )
( s ,t )S xy
Q 1

fˆ ( x, y ) 
 g ( s ,
( s ,t )S xy
t ) Q

Q is the order of the filter and adjusting its


value changes the filter’s behaviour
Positive values of Q eliminate pepper noise
Negative values of Q eliminate salt noise
Noise Removal Examples

Image
Original Corrupted
Image By Gaussian
Noise

After A 3*3 After A 3*3


Arithmetic Geometric
Mean Filter Mean Filter
Noise Removal Examples (cont…)

Image
Corrupted
By Pepper
Noise

Result of
Filtering Above
With 3*3
Contraharmonic
Q=1.5
Noise Removal Examples (cont…)

Image
Corrupted
By Salt
Noise

Result of
Filtering Above
With 3*3
Contraharmonic
Q=-1.5
Contraharmonic Filter:

Choosing the wrong value for Q when using


the contraharmonic filter can have drastic
results
Order Statistics Filters
Spatial filters that are based on ordering the
pixel values that make up the
neighbourhood operated on by the filter
Useful spatial filters include
– Median filter
– Max and min filter
– Midpoint filter
– Alpha trimmed mean filter
Median Filter
Median Filter:
fˆ ( x, y )  median{g ( s, t )}
( s ,t )S xy

Excellent at noise removal, without the


smoothing effects that can occur with other
smoothing filters
Particularly good when salt and pepper
noise is present
Max and Min Filter
Max Filter:
fˆ ( x, y )  max {g ( s, t )}
( s ,t )S xy

Min Filter:
fˆ ( x, y )  min {g ( s, t )}
( s ,t )S xy

Max filter is good for pepper noise and min


is good for salt noise
Midpoint Filter
Midpoint Filter:
ˆf ( x, y )  1  max {g ( s, t )}  min {g ( s, t )}
2 ( s ,t )S xy ( s ,t )S xy 
Good for random Gaussian and uniform
noise
Alpha-Trimmed Mean Filter
Alpha-Trimmed Mean Filter:
ˆf ( x, y )  1
 g r ( s, t )
mn  d ( s ,t )S xy

We can delete the d/2 lowest and d/2 highest


grey levels
So gr(s, t) represents the remaining mn – d
pixels
Noise Removal Examples

Image Result of 1
Corrupted Pass With A
By Salt And 3*3 Median
Pepper Noise Filter

Result of 2 Result of 3
Passes With Passes With
A 3*3 Median A 3*3 Median
Filter Filter
Noise Removal Examples (cont…)

Image Image
Corrupted Corrupted
By Pepper By Salt
Noise Noise

Result Of Result Of
Filtering Filtering
Above Above
With A 3*3 With A 3*3
Max Filter Min Filter
Noise Removal Examples (cont…)
Image Image Further
Corrupted Corrupted
By Uniform By Salt and
Noise Pepper Noise

Filtered By Filtered By
5*5 Arithmetic 5*5 Geometric
Mean Filter Mean Filter

Filtered By Filtered By
5*5 Median 5*5 Alpha-Trimmed
Filter Mean Filter
Periodic Noise
Typically arises due to
electrical or electromagnetic

interference
Gives rise to regular noise
patterns in an image
Frequency domain
techniques in the Fourier
domain are most effective
at removing periodic noise
Band Reject Filters
Removing periodic noise form an image
involves removing a particular range of
frequencies from that image
Band reject filters can be used for this purpose
An ideal band reject filter is given as follows:
 W
1 if D(u, v)  D0  2
 W W
H (u , v)  0 if D0   D(u, v)  D0 
 2 2
1 if D(u, v)  D0  W
 2
Band Reject Filters (cont…)
The ideal band reject filter is shown below,
Images taken from Gonzalez & Woods, Digital Image Processing (2002)

along with Butterworth and Gaussian


versions of the filter

Ideal Band Butterworth Gaussian


Reject Filter Band Reject Band Reject
Filter (of order 1) Filter
Band Reject Filter Example
Image corrupted by Fourier spectrum of
sinusoidal noise corrupted image

Butterworth band Filtered image


reject filter
Summary
In this lecture we will look at image restoration
for noise removal
Restoration is slightly more objective than
enhancement
Spatial domain techniques are particularly
useful for removing random noise
Frequency domain techniques are particularly
useful for removing periodic noise

You might also like