Docsity

Image Restoration part 2-Digital Image Processing-Lecture Slides, Slides of Digital Image Processing

Partial preview of the text

Download Image Restoration part 2-Digital Image Processing-Lecture Slides and more Slides Digital Image Processing in PDF only on Docsity!

20

Restoration of noise onlydegradation Degraded Image

)^

In spatial domain:

)^

)^

In frequency domain:

g x y

G u v

g x y

f^

x y

x y

G u v

F u v

 N u v

^

^

Considering H = 1 (a unity function)

degradation only involves

noise

21

Restoration of noise onlydegradation: Restoration filters ^

Mean filters ^

Arithmetic mean filter ^

Geometric mean filter ^

Harmonic mean filter ^

Contraharmonic mean filter

^

Order statistics filters ^

Median filter ^

Max and Min filter ^

Midpoint filter ^

Alpha-trimmed mean filter

23

Arithmetic mean filter ^

Smooth local variation in an image ^

Noise is reduced as a result of blurring ^

g(s,t):

degraded image

^

S

: set of coordinates in a rectangular subimage of xy size

mxn

centered at point (x,y)

^

The above operation can be implemented using aconvolution mask in which all coefficients have value1/mn i.e. a box filter

( , )

)^

xy s t^

S

f^

x y

g s t

mn

^

24

Geometric and harmonic meanfilters ^

Geometric mean filter ^

Comparable to arithmetic mean filter

achieves

smoothing but loss less details in the image

^

Harmonic mean filter ^

Works well for salt noise, fails for pepper noise ^

Does well with other types of noise like Gaussian noise

1

( , )

( ,

)^

( , ) xy

mn

s t^

S

f^

x y

g s t  ^

 

^

^

Each restored pixel is givenby the product of the pixelsin the subimage window,raised to power 1/mn

( , )

( ,

)

(^1) ( , ) xy s t^

mn S

f^

x y

g s t  

26

Contraharmonic mean filter ^

Q > 0, eliminate pepper noise ^

Q < 0, eliminate salt noise ^

Q = 1, arithmetic mean filter ^

Q = -1, harmonic mean filter ^

Cannot eliminate both salt noise and pepper noisesimultaneously

^

^

1

( , ) ( , )

)^
:Order of the filter

xy xy

Q

s t^

S

Q

s t^

S

g s t
f^
x y
g s t
Q

 

 

27

Contraharmonic mean filter ^

The

positive

order

filter

effectively

reduces

the

pepper noise at the expense of blurring the darkareas ^

The negative order filter effectively reduces the saltnoise at the expense of blurring the bright areas ^

It suits the impulse noise yet with the information ofdark or light noise to select the proper sign of orderof filter (Q)

29

Contraharmonic mean filter:Result of selecting wrong sign of filter order

Order statistics filters

32

Median filter: Example

33

Max and Min filters ^

Max filterReplace the value of a pixel by the maximum of the graylevels (the brightest point) in the neighborhood of that pixel ^

Min filterReplace the value of a pixel by the minimum of the gray levels(the darkest point) in the neighborhood of that pixel

^

^

( , )

( ,

)^

max

( , ) xy s t

S

f^

x y

g s t

^

^

( , )

( ,

)^

min

( , )

xy s t

S

f^

x y

g s t

35

Midpoint filter ^

Filter output is the midpoint between maximum andminimum values of the gray levels in a subimage ^

Combines order statistics and averaging ^

Midpoint filter works best for randomly distributednoise (Gaussian or uniform noise)

^

^

^

( , )

( , ) 1

( ,

)^

max

( , )

min

( , )

2

xy

xy^

s t^

S

s t

S

f^

x y

g s t

g s t

 ^

^

^

^

36

Alpha-trimmed mean filter ^

Suppose that we delete the d/2 lowest and d/2 highestgray level values in a subimage S

xy^

and let g

(s,t)r

represent the remaining (mn-d) pixels ^

Alpha-trimmed mean filter is given by: ^

If d = 0 then it is an arithmetic mean filter ^

If d = (mn-1)/2 then it is a median filter

^

This filter can be used to solve multiple type noiseproblem e.g. combination of salt-and-pepper andGaussian noise

( , ) 1

( ,

)^

( , )

0

(^

xy 1)

r

s t^

S

f^

x y

g^

s t

mn

d

where

d^

mn

^

 ^

^

 