detail preserving impulsive noise removalpapersim.com/wp-content/uploads/detail_preserving... ·...
TRANSCRIPT
ARTICLE IN PRESS
0923-5965/$ - se
doi:10.1016/j.im
�Correspondi
ing Department
6P4, Canada. T
E-mail add
uwaterloo.ca
(M. Kamel), jer
Signal Processing: Image Communication 19 (2004) 993–1003
www.elsevier.com/locate/image
Detail preserving impulsive noise removal
Naif Alajlana,�, Mohamed Kamela, Ed Jerniganb
aPAMI Lab, Electrical and Computer Engineering Department, University of Waterloo, Waterloo, ON N2L 3G1, CanadabSystems Design Engineering Department, University of Waterloo, Waterloo, ON N2L 3G1, Canada
Received 13 January 2004
Abstract
Most image processing applications require noise elimination. For example, in applications where derivative
operators are applied, any noise in the image can result in serious errors. Impulsive noise appears as a sprinkle of dark
and bright spots. Transmission errors, corrupted pixel elements in the camera sensors, or faulty memory locations can
cause impulsive noise. Linear filters fail to suppress impulsive noise. Thus, non-linear filters have been proposed.
Windyga’s peak-and-valley filter, introduced to remove impulsive noise, identifies noisy pixels and then replaces their
values with the minimum or maximum value of their neighbors depending on the noise (dark or bright). Its main
disadvantage is that it removes fine image details. In this work, a variation of the peak-and-valley filter is proposed to
overcome this problem. It is based on a recursive minimum–maximum method, which replaces the noisy pixel with a
value based on neighborhood information. This method preserves constant and edge areas even under high impulsive
noise probability. Finally, a comparison study of the peak-and-valley filter, the median filter, and the proposed filter is
carried-out using different types of images. The proposed filter outperforms other filters in the noise reduction and the
image details preservation. However, it operates slightly slower than the peak-and-valley filter.
r 2004 Elsevier B.V. All rights reserved.
Keywords: Image smoothing; Median filter; Impulsive noise; Non-linear filtering
1. Introduction
Filtering a digital image to attenuate noise whilepreserving the image detail is an essential part ofimage processing. For example, in many applica-
e front matter r 2004 Elsevier B.V. All rights reserve
age.2004.08.003
ng author. Electrical and Computer Engineer-
, University of Waterloo, Waterloo, Ont., N2L
el.: +1-519-895-6100; fax: +1-519-746-3077.
resses: [email protected], naif@pami.
(N. Alajlan), [email protected]
[email protected] (E. Jernigan).
tions where operators based on computing imagederivatives are applied, any noise in the image canresult in serious errors. In addition, there is anincreasing need of fast filters for the reduction ofimpulsive noise in real-time videos. Noise canappear in images from a variety of sources duringthe acquisition process, due to quality and resolu-tion of cameras, and illumination variations. Formost typical applications, image noise can bemodeled with either Gaussian, uniform, or im-pulsive distributions. Gaussian noise can be
d.
ARTICLE IN PRESS
Fig. 1. Window used to detect and process impulsive noisy
pixels.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003994
analytically described and has the bell shapecharacteristic. With uniform noise, the gray levelvalues of the noise are evenly distributed across aspecific range. Impulsive noise generates pixelswith gray level values not consistent with theirlocal neighbors. It appears in the image as asprinkle of dark and light spots. Transmissionerrors, malfunctioning pixel elements in thecamera sensors, or faulty memory locations cancause impulsive noise.
Linear filters, which consist of convolving theimage with a constant matrix, fail to deal withimpulsive noise although they are effective inreducing Gaussian and uniform noise. Theyusually produce blur and incomplete impulsivenoise suppression [6]. To overcome these difficul-ties, non-linear filters have been proposed. Themost popular non-linear filter is the median filter.When considering a small neighborhood, it ishighly efficient in removing impulsive noise. Themain disadvantage of the median filter is that it isapplied on all the points of the image regardless ifthey are noisy or not, which results in the loss offine image detail and produces streaks andblotches in the restored image [10]. Finding amethod that is efficient in both noise reduction anddetail preservation is an active area of research.
Various forms of non-linear techniques havebeen introduced to solve the problem based on theaverage performance of the median filter. Exam-ples of those techniques are the weighted medianfilter [2], the adaptive trimmed mean filter [7], thecenter weighted median filter [5], the switching-based median filter [8], the mask median filter [3],and the minimum–maximum method [4]. Theseapproaches involve a preliminary identification ofcorrupted pixels in an effort to prevent alterationof true pixels. The recursive minimum–maximumfilter [10] performs better than other filters includ-ing the standard median filter. It is good atpreserving fine details, but its main disadvantageis that it requires thresholding to detect noisypixels, which may require several iterations toachieve its best results since each image region hasdifferent properties. Consequently, the efficiency isreduced. To overcome the thresholding problem,the peak-and-valley filter [9] others a fast and non-iterative method to detect noisy pixels and then it
replaces their values with the minimum or max-imum of the neighbor’s values.
In this work, an efficient and detail preservingfilter for impulsive noise removal is proposed. It isbased on the peak-and-valley filter [9] and therecursive minimum–maximum method [10] andworks in two stages. First, it detects noisy pixels byexamining the surrounding pixels as in the peak-and-valley filter. Then, it replaces the noisy pixelvalues using the recursive minimum–maximummethod. The remaining of the paper is organizedas follows. Sections 2 and 3 give explanations ofthe median and peak-and-valley filters, respec-tively. Section 4 introduces our proposed filterfollowed by comparative studies of its perfor-mance with the median and peak-and-valley filtersin Section 5. Finally, we conclude our work inSection 6.
2. The median filter
Beside being one of the first non-linear filtersthat has been proposed, the median filter is themost popular example of non-linear filters basedon order statistics. Due to this fact, an optimizedimplementation of the median filter is available.Consider a 3� 3 window shown in Fig. 1, theoutput of an order statistic filter is given by
y ¼X9
i¼1
aidki ; (1)
where dki are the order statistics of the nine inputs.
The constant ai may be chosen for a particular
ARTICLE IN PRESS
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003 995
application. The median filter is a particular caseof (1) with the coefficients ai ¼ 0 except a5 ¼ 1:We can also define the local mean filter by takingai ¼ 1=9:
Bovik et al. [1] showed that the optimal orderstatistic filter tends toward the median filter as thenoise becomes more impulsive, based on theminimum mean squared error between the originalnoise-free and noisy filtered images. The medianfilter is effective when the noise spatial extent isless than half the window size.
3. The peak-and-valley filter
The peak-and-valley filter is a non-linear non-iterative filter for impulsive noise reduction basedon order statistics and a minimal use of thebackground information. It consists of applyingtwo conditional rules. The noisy pixels areidentified and replaced in a single step. Thereplacement gray value is taken from the neigh-bors’ gray levels. Furthermore, the peak-and-valley filter has generic nature, i.e., it can bemodified to handle different noise sizes, it can bescaled to 3D, and it can be implemented as asequence of 1D filters (or 2D filters for 3Dnoise).
To understand how the peak-and-valley filterworks, consider the 1D case where it takes thefollowing shape:
yi ¼
minðdi�1; diþ1Þ if diominðdi�1; diþ1Þ;
maxðdi�1; diþ1Þ if di4maxðdi�1; diþ1Þ;
di otherwise:
8><>:
(2)
The peak-and-valley filter eliminates all thepeaks and valleys which are thinner than twopixels and fills them following a sequence ofcutting/filling then filling/cutting operations, whiledisplacing all along the rows and columns of theimage. For the cutting operation, if the middlepixel has a gray level higher than its two neighbors,its gray level value is replaced by the maximum ofthe other two. For the filling operation, if themiddle pixel is smaller than the other two, its graylevel value is replaced by the smallest value among
its neighbors. All these operations are recursivelyapplied to assure that no peaks and/or valleysremain in the filtered image. It is arguably thefastest filter proposed so far, although not themost efficient filter in terms of impulsive noiseremoval.
The expression of the filter for the 2D case,considering 3� 3 window shown in Fig. 1 and i 2
½1 : 8; is
y ¼
minðdiÞ if d9ominðdiÞ;
maxðdiÞ if d94maxðdiÞ;
d9 otherwise:
8><>:
(3)
4. The proposed filter
The proposed filter is a non-linear, non-iterativefilter that is based on order statistics to removeimpulsive noise from an image. It operates in twosteps. In the first step, the noisy pixels are detectedin the same manner as in the peak-and-valley filter.Then, the corrupted pixels’ gray level values areestimated using the recursive minimum–maximummethod. Two motivations are behind this work:(1) to have a simple and non-iterative noisedetection approach that enables the filter to beapplicable to all image types; and (2) to avoidmodifying all pixels that destroys fine image detailslike the median filter. In the second step, therecursive minimum–maximum method providesan estimate of the corrupted pixels at constantsignal as well as edges even when the noiseprobability is high. This estimation of the originalpixel’s value is more realistic than the estimationused in the peak-and-valley filter, which is just theminimum or maximum value of the surroundingpixels. More specifically, the proposed algorithmfor impulsive noise filtering works as follows:
(1)
For a 3� 3 window centered at the test pixel,as shown in Fig. 1.(2)
If d9XmaxðdiÞ or d9pminðdiÞ where 1pip8;then d9 is a noisy pixel and must be estimated,go to step 3. Otherwise y=d9.(3)
When a noisy pixel is detected, its gray levelis estimated as follows. For 1pip4; letARTICLE IN PRESS
Fig.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003996
Li ¼ maxðdi; d9�iÞ and Ei ¼ minðdi; d9�iÞ: SetPmin ¼ minðL1; . . . ;L4Þ and Pmax ¼
maxðE1; . . . ;E4Þ: Then y ¼ ðPmin þ PmaxÞ=2:
Note that if there are three identical noisy pixelsalong one direction within the window, then theoutput of the filter is largely influenced by thenoisy pixels. In this case, either Pmax or Pmin isequal to the level of the noisy pixel. However,(d1, d2, d3, d4) in Fig. 1 are in practice the previousoutputs of the filter, instead of the originaldegraded image data. Thus, the output of thefilter is derived recursively from the last fouroutputs and the present five inputs in the window.
(a)
(a)
(c)
(e)
2. Hamburg taxi images and filtering results: (a) original, (b) 30%
5. Comparative studies
We implemented the median, the peak-and-valley, and the proposed filters to compare theirperformance. To provide consistent comparison,only the recursive versions of these filters areconsidered. The peak-and-valley filter is imple-mented as a pair of 1D filters, applied in thehorizontal then in the vertical directions becausethis version provides the best performance [9]. Wetested the performance of the filters on fourstandard images used by the image processingresearch community. The first one was the firstframe of a public domain twelve-frame sequence,
(b)
(d)
(b)
(d)
corrupted, (c) median, (d) peak-and-valley, and (e) proposed.
ARTICLE IN PRESS
(a) (b)
(d)
(a) (b)
(c) (d)
(e)
Fig. 3. Cameraman images and filtering results: (a) original, (b) 30% corrupted, (c) median, (d) peak-and-valley, and (e) proposed.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003 997
known as Hamburg taxi (190� 256 pixels), shownin Fig. 2(a). The second was the cameraman image(256� 256 pixels), shown in Fig. 3(a). The thirdimage was the well-known Lena image (512� 512pixels), shown in Fig. 4(a). The fourth image was
the Baboon image (512� 512 pixels), shown inFig. 5(a). The images contain a nice mixture ofdetail, flat regions, shading, and texture that do agood job of testing various image processingalgorithms. We restricted our tests to a 3� 3
ARTICLE IN PRESS
(a) (b)
(d)
(a) (b)
(c) (d)
(e)
Fig. 4. Lena images and filtering results: (a) original, (b) 50% corrupted, (c) median, (d) peak-and-valley, and (e) proposed.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003998
window size to reduce the computational complexityof the algorithms. The algorithms were implementedin MATLAB 6.5 on PC workstation with a Pentium3 GHz and 500 MB RAM, running Windows XP.
To assess the quality of the visual appearance,four performance measures are used to comparethe filters [9]: the number of the noisy pixelsreplaced by the true values, the number of noisy
ARTICLE IN PRESS
(a) (b)
(d)
(a) (b)
(c) (d)
(e)
Fig. 5. Baboon images and filtering results: (a) original, (b) 70% corrupted, (c) median, (d) peak-and-valley, and (e) proposed.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003 999
pixels attenuated, the number of true pixelsmodified, and the mean squared error between theoriginal noise-free and filtered images. All imageswere corrupted with impulsive noise with prob-ability ranging from 1% to 99%. The outcomes of
the median, peak-and-valley, and the proposedfilters applied to the four test images at differentimpulsive noise probabilities are shown in Figs. 2–5.The four performance measures are plotted versusthe impulsive noise probability in Figs. 6–9.
ARTICLE IN PRESS
0 0.2 0.4 0.6 0.8 10
0.05
0.1
0.15
0.2
0.25
0.3
0.35
Noise Probability
% n
oise
elim
inat
ed
0 0.2 0.4 0.6 0.8 10.2
0.4
0.6
0.8
1
Noise Probability
% n
oise
atte
nuat
ed
0 0.2 0.4 0.6 0.8 10
0.2
0.4
0.6
0.8
Noise Probability
% im
age
spoi
led
0 0.2 0.4 0.6 0.8 10
5000
10000
15000
Noise Probability
MS
E
MedianP and VProposed
Fig. 6. Objective performances on the Hamaburg Taxi image.
0 0.2 0.4 0.6 0.8 10
0.05
0.1
0.15
0.2
Noise Probability
% n
oise
elim
inat
ed
0 0.2 0.4 0.6 0.8 10.2
0.4
0.6
0.8
1
Noise Probability
% n
oise
atte
nuat
ed
0 0.2 0.4 0.6 0.8 10
0.2
0.4
0.6
0.8
Noise Probability
% im
age
spoi
led
0 0.2 0.4 0.6 0.8 10
0.5
1
1.5
2x 104
Noise Probability
MS
E
Median
ProposedP and V
Fig. 7. Objective performances on the Cameraman image.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–10031000
ARTICLE IN PRESS
0 0.2 0.4 0.6 0.8 10
0.05
0.1
0.15
0.2
Noise Probability
% n
oise
elim
inat
ed
0 0.2 0.4 0.6 0.8 10.2
0.4
0.6
0.8
1
Noise Probability
% n
oise
atte
nuat
ed
0 0.2 0.4 0.6 0.8 10
0.2
0.4
0.6
0.8
Noise Probability
% im
age
spoi
led
0 0.2 0.4 0.6 0.8 10
2
4
6
8x 104
Noise Probability
MS
E
MedianP and VProposed
Fig. 8. Objective performances on the Lena image.
0 0.2 0.4 0.6 0.8 10
0.01
0.02
0.03
0.04
0.05
0.06
0.07
Noise Probability
% n
oise
elim
inat
ed
0 0.2 0.4 0.6 0.8 10.2
0.4
0.6
0.8
1
Noise Probability
% n
oise
atte
nuat
ed
0 0.2 0.4 0.6 0.8 10
0.2
0.4
0.6
0.8
Noise Probability
% im
age
spoi
led
0 0.2 0.4 0.6 0.8 10
2
4
6
8x 104
Noise Probability
MS
E
MedianP and VProposed
Fig. 9. Objective performances on the Baboon image.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003 1001
ARTICLE IN PRESS
0
2
4
6
8
10
12
14
16
18
20
Hamburg taxi Baboon Lena Cameraman
MedianP-and-VProposed
Tim
e (s
econ
ds)
Fig. 10. Execution times (in seconds), averaged over 1% to
99% contamination levels, of the three filters applied on
different images.
(b)
(a)
(c)
(e)
Fig. 11. Comparison of how different filters preserve fine image deta
Valley, and (e) proposed.
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–10031002
For all images, the proposed filter attenuatesimpulsive noise much more efficiently than theother filters even when the noise probability ishigh. The peak-and-valley filter noise attenuationrate reduces dramatically as the noise probabilityincreases. The median filter is the best in terms ofestimating the actual value of a noisy pixel, but ittends to change the values of more than 50% oftrue pixels, which results in destroying fine detailsin the image. Interestingly, the proposed filtermodifies fewer true pixels as the noise probabilityincreases, which results in high detail preservation.Also, the proposed filter outperforms other filtersin the minimum mean squared error sense. Interms of speed, Fig. 10 shows that the peak-and-valley filter is slightly faster than the proposedfilter and the median filter is the slowest. This isdue to the fact that the median filter operates on
(b)
(d)
ils: (a) original, (b) 30% corrupted, (c) median, (d) Peak-and-
ARTICLE IN PRESS
N. Alajlan et al. / Signal Processing: Image Communication 19 (2004) 993–1003 1003
all image pixels while the others operate only onthe detected noisy pixels. From these results, theproposed filter outperforms other filters in theoverall performance.
To show how the proposed filter preserves fineimage details, Fig. 11 shows zoomed images of theright eye in the Lena image of Fig. 4. It is clear thatthe proposed filter is able to preserve fine imagedetails better than the median and the peak-and-valley filters.
6. Conclusion
In this work, we proposed a non-linear, non-iterative filter for impulsive noise attenuation.Unlike thresholding techniques, it detects noisypixels non-iteratively using the surrounding pixelvalues, which makes it suitable for all image types.The filter uses the recursive minimum–maximummethod to estimate the value of corrupted pixels.This provides an accurate estimation even whenthe noise probability is high. The performance ofthe proposed filter is compared with two otherfilters, the median and the peak-and-valley. Theproposed filter out-performed other filters in termsof noise attenuation and detail preservation.However, the proposed filter operates slightlyslower than the peak-and-valley filter and fasterthan the median filter. In conclusion, the proposedfilter represents an interesting alternative to themedian filter, which is used for preliminary
processing in most of the state-of-the-art impulsivenoise filters.
References
[1] A.C. Bovik, T. Huang, D. Munson, A generalization of
median filtering using linear combinations of order
statistics, IEEE Trans. Acoust. Speech Signal Proc. 31
(1983) 1342–1350.
[2] D. Brownrigg, The weighted median filter, Commun.
ACM 27 (1984) 807–818.
[3] L. Cabrera, P. Escanmilla, Two pixel preselection methods
for median type filtering., Vision, Image Signal Proc. IEE
Proc. 145 (1998) 30–40.
[4] M. Imme, A noise peak elimination filter, CVGIP: Graph.
Models Image Proc. 53 (1991) 204–211.
[5] S.J. Ko, Y.H. Lee, Center weighted median filters and their
applications to image enhancement, IEEE Trans. Circuits
Syst. 38 (1991) 984–993.
[6] H.G. Moreno, S.M. Bascon, M.U. Manso, P.M. Martin,
Elimination of impulsive noise in images by means of the
use of support vector machines, XVI National Symposium
of URSI, 2001, pp. 1–2.
[7] A. Restrepo, A.C. Bovik, Adaptive trimmed mean filters
for image restoration, IEEE Trans. Acoust. Speech, Signal
Proc. 36 (1988) 1326–1337.
[8] T. Sun, Y. Neuvo, Detail preserving median based filters in
image processing, Pattern Recogn. Lett. 15 (1994)
341–347.
[9] P.S. Windyga, Fast impulsive noise removal, IEEE Trans.
Image Proc. 10 (2001) 173–179.
[10] Y. Xu, E.M. Lae, Restoration of images contaminated by
mixed gaussian and impulse noise using a recursive
minimum–maximum method, Vision Image Signal Proc.
IEE Proc. 145 (1998) 264–270.