a morphological approach to remove salt and pepper noise in images
a morphological approach to remove salt and pepper noise in images
a morphological approach to remove salt and pepper noise in images
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Arav<strong>in</strong>th Ch<strong>in</strong>napalanichamy et al ,Int.J.Computer Technology & Applications,Vol 3 (6), 1875-1880<br />
ISSN:2229-6093<br />
The steps <strong>in</strong>volved <strong>in</strong> phase 1 are specified as follows:<br />
1. The process<strong>in</strong>g pixel f(x, y) is extracted along with<br />
its neighbourhood pixels. The mask size is chosen<br />
accord<strong>in</strong>g <strong>to</strong> the <strong>noise</strong> density<br />
<strong>noise</strong> pixels occupy<strong>in</strong>g a very less area of the bell shaped<br />
curve of normal distribution (i.e.) the <strong>noise</strong> occupies only both<br />
the extremes <strong>and</strong> the <strong>noise</strong> free pixels are centred on the mean<br />
value of the neighbourhood.<br />
MASK SIZE NOISE<br />
DENSITY<br />
3 X 3 0-30%<br />
5 X 5 30-60%<br />
7 X 7 60- 90%<br />
For <strong>in</strong>creas<strong>in</strong>g <strong>noise</strong> density, the mask size should<br />
also be l<strong>in</strong>early <strong>in</strong>creased for better <strong>noise</strong><br />
identification. However <strong>in</strong>creas<strong>in</strong>g the mask size<br />
also imposes a blurry effect on the res<strong>to</strong>red image.<br />
G = f x + s, y + t were s, t = −k <strong>to</strong> k<br />
<strong>and</strong> (2k + 1 X 2k + 1) is te mask size<br />
1. The proposed scheme is applied for an 8 bit image<br />
(Intensity range-0 <strong>to</strong> 255). The centre pixel is<br />
verified for 0 or 255. If it is one of the two values,<br />
then it is reta<strong>in</strong>ed as a possible c<strong>and</strong>idate for <strong>noise</strong>.<br />
Or else it is considered as <strong>noise</strong> free <strong>and</strong> the next<br />
pixel along with its neighbourhood is taken for<br />
process<strong>in</strong>g.<br />
N(x, y) =<br />
1, f x, y = 0 or 255<br />
0, else<br />
2. If N(x, y) =1, then the matrix G is checked for<br />
values 0 <strong>and</strong> 255. If all the values <strong>in</strong> G are 0 <strong>and</strong><br />
255, then sub stage 1 is used <strong>and</strong> if there are<br />
different <strong>in</strong>tensity levels (0 <strong>to</strong> 255), then sub stage 2<br />
is selected for <strong>noise</strong> identification.<br />
G =<br />
substage 1, G(G ≠ 0 |255 = 0<br />
substage 2, else<br />
3.1 Sub stage 1- Image res<strong>to</strong>ration <strong>in</strong> white<br />
<strong>and</strong> black regions<br />
The w<strong>in</strong>dow extracted from a white or black region<br />
from a <strong>noise</strong> free image will have all its values as either 0 or<br />
255 .However if impulse <strong>noise</strong> is present, depend<strong>in</strong>g on <strong>noise</strong><br />
density level, noisy 0 values replace some of the 255 values<br />
<strong>in</strong> white region <strong>and</strong> vice versa. But the majority of the pixels<br />
<strong>in</strong> a chosen w<strong>in</strong>dow will be either 0 or 255 based on the<br />
region. Hence the no of 0’s <strong>and</strong> 255’s <strong>in</strong> the w<strong>in</strong>dow is<br />
counted <strong>and</strong> f(x, y) is replaced with the value occurr<strong>in</strong>g<br />
maximum no of times.<br />
f x, y =<br />
0, Na > Nb<br />
255, else<br />
were Na = no of 0 ′ s <strong>in</strong> G <strong>and</strong> Nb = no of 255 ′ s <strong>in</strong>G.<br />
3.2 Sub stage 2- Noise Identification <strong>in</strong><br />
Gray shade regions<br />
The distribution of pixels <strong>in</strong> a particular<br />
neighbourhood follows nearly a normal distribution with the<br />
68% of the <strong>to</strong>tal area of the curve is always<br />
considered as <strong>noise</strong> for process<strong>in</strong>g accord<strong>in</strong>g <strong>to</strong> the algorithm<br />
although it may also conta<strong>in</strong> some noisy pixels for higher<br />
<strong>noise</strong> densities. As proposed earlier, pixel connectivity is used<br />
<strong>to</strong> identify a noisy pixel. Hence connectivity is established<br />
between the pixels conta<strong>in</strong>ed with<strong>in</strong> the rema<strong>in</strong><strong>in</strong>g 32% of the<br />
curve. This portion of the curve may also conta<strong>in</strong> some <strong>noise</strong><br />
free pixels. However, this does not cause significant problem<br />
for <strong>noise</strong> identification.<br />
For establish<strong>in</strong>g connectivity, certa<strong>in</strong> conditions are<br />
specified based on which the <strong>in</strong>tensity values <strong>in</strong> the extracted<br />
w<strong>in</strong>dow are changed <strong>to</strong> either 0 (background pixel) or<br />
1(foreground pixel) <strong>and</strong> a 4-connectivity is established<br />
between the foreground pixels (1). The connection thus<br />
established between the foreground pixels is actually a<br />
connection among the noisy pixels <strong>in</strong> the chosen w<strong>in</strong>dow.<br />
This procedure is given <strong>in</strong> the follow<strong>in</strong>g steps.<br />
1. A function H is found which is a subset of G with G<br />
(centre) <strong>remove</strong>d. Then the mean (µ) <strong>and</strong> st<strong>and</strong>ard<br />
deviation (σ) of H is found. From that, two values (R1 <strong>and</strong><br />
R2) are found.<br />
R1=µ-σ <strong>and</strong> R2=µ+σ<br />
It is seen that almost all the <strong>noise</strong> free pixels are<br />
conta<strong>in</strong>ed with<strong>in</strong> this range <strong>and</strong> the noisy values are located<br />
outside the range. However there are certa<strong>in</strong> cases like <strong>images</strong><br />
with high <strong>noise</strong> density or regions with <strong>in</strong>tensity values closer<br />
<strong>to</strong> 0 & 255 where the noisy pixels are also <strong>in</strong>cluded <strong>in</strong> the<br />
range because the mean will be centred on 0 or 255 <strong>in</strong> either<br />
case.<br />
2. Now the values of H are converted <strong>to</strong> any of the three<br />
values 0, 255 <strong>and</strong> constant K based on the follow<strong>in</strong>g<br />
conditions. This is based on the assumption that the values<br />
conta<strong>in</strong>ed with<strong>in</strong> the range R are <strong>noise</strong> free <strong>and</strong> those<br />
outside the range are <strong>noise</strong>.<br />
IJCTA | Nov-Dec 2012<br />
Available onl<strong>in</strong>e@www.ijcta.com<br />
1876