Impulse noise features for automatic selection of noise cleaning filter Odej Kao Department of Computer Science Technical University of Clausthal Julius-Albert-Strasse 37 Clausthal-Zellerfeld, Germany Abstract The noise removal is an important aspect of image processing, because the human visual system is very sensitive to the high amplitude of noise signals, thus noise in an image can result in a subjective loss of information. There are a lot of methods for impulse noise removal like the median or the outlier filter. But there are only few measuring methods for the quality of a smoothed image. In most cases the developed filters are tested on standard images. On the other hand it is difficult to decide, which filter should be used for a given image with impulse noise introduced to it. In this paper two methods for impulse noise removal are compared in order examine important features for an automatic detection of adequate smoothing operators for a given noisy image. The quality of the smoothed image depends on two parameters: the quantity of impulse noise and the structure of the noisy image. These can be characterised and used for an automatic choice and for the setting of the appropriate filter options. Keywords: image processing, impulse noise features, outlier, ranking 1. Introduction Impulse noise is a special type of noise which can have many different causes. Thus, in the case of satellite or TV images it can be caused through atmospheric disturbances. In other applications it can be caused by strong electromagnetic fields, transmission errors, etc. Impulse noise is characterised by short, abrupt alterations of the colour values in the image. The concerned points are changed through overlay of a coincidence value so that they differ significantly from their local Stefan Diener Imaging GmbH PO BOX 11 73 Oberkochen, Germany neighbourhood and disturb the natural colour run. Thereby the subsequent image processing, analysis and evaluation can be affected, regardless whether these actions are done by a human viewer or in an automated process. This is the reason why smoothing operators form the foundation of each image processing chain. The aim is to approximately restore the original value of the noisy point. A lot of filters for impulse noise removal [1,,3,] have been developed. Usually they are subdivided into linear and non linear filters. Another classification is based on the used image description space, so the filters fall into two classes: spatial and frequency domain filter. Frequency domain operators have usually low-pass properties. By introduction of a threshold value, so called cut-off-frequency, the high image frequencies are eliminated and the impulse noise level can be decreased. An essential disadvantage of this method is that other image components with high frequency, like edges, are affected resulting in a blurred image. Spatial domain filters work directly on the image matrix. Different methods can be used in order to identify and eliminate outliers in an examined image environment. A standard filter in this class is the median filter, which was proposed by Tukey [5]. However, there exist plenty of specialised impulse noise removal filters, which are adapted to specific image classes. Thus the
achieved smoothing results are better as the results of the median filter in these special applications. A general control criterion for the quality of a noise suppression does not exist because this depends on the actual application. The demands on smoothing of a high-resolution picture, which is the input for precise measurements, distinguish from the demand on smoothing of a television frame. Further an exact mathematical model of an ideal picture defining image features like contrast, colour distribution etc. is still not available, because the set of possible pictures is not manageable. The operators are applied and matched to general test patterns and the smoothing results are usually evaluated visually. The subjective opinion of the observer has thereby an essential meaning. Therefore, the application of such operators to general and specific problems is an iterative process. The picture is added to a set of available noise removal operators. Subsequently a visual evaluation of the smoothed image follows. In the case of complicated or sensitive processes essential image components must be enlarged and properly examined. Beside the large time effort a certain work experience with image processing operators is required. This process can be enhanced and speeded up by an analysis of the impulse noise and of the image structure. The results of this analysis should be image features like e.g. noise distributions, detail degrees etc. These can be used for an automatic choice of the noise removal filter and the corresponding parameters. Thus the operators can be easily applied by users without certain image processing knowledge. The first step in this direction is a comparison of the available noise removal filters in order to determine essential features, which can be used as a basis for a problem oriented classification. In this paper the properties of two standard methods, the outlier and the rank order method, are examined and compared.. Outlier method In case of the outlier method an average of the grey levels in a n n filter window, n odd, around the center pixel is calculated. This can be performed by using following mask: 1 1 1 1 1 1 1 1 1 In the next step an absolute difference d of the average value and the grey level of the center pixel is calculated and compared with a threshold value t. The analysed pixel is marked as a noise peak, if d>t. The success of this method for noise removal depends on the choice of the threshold value t. Many peaks can not be recognised, if the value t is too big. Otherwise too many non noisy points can be marked as peaks. Figure 1: Test images Lena, Corvette
outlier method, Amplitude (Lena) outlier method, Amplitude 55 (Lena) 1 1 1 5 1-1 - - - - Figure : Hit rate in case of the outlier method and the image Lena There are four possibilities for the marking of an image point: 1) a point is a peak and correctly marked (hit_peak) ) a marked point is not a peak (miss_point) 3) a peak is not marked (miss_peak) ) a point without noise is not marked (hit_point) These values are used for the calculation of a hit/miss quotient as follows: h_peak h/m_rate= 1 % h_peak+ m_peak+ m_point [ ] In order to examine the dependencies of the removal quality and the threshold value practical tests on two selected images, "Lena" and "Corvette" (Figure 1), were executed. We used a 3 3 filter window and examined white and black impulse noise points in two different passes. The results of these tests are shown in figure. With a threshold value t between and 7 a hit/miss rate of approximately % - 9% can be reached. Beyond that threshold there is no relevant increase in the removal. Further there exists no significant difference in the removal of white or black noisy peaks. The hit/miss rate falls with a larger noise component in the image. The amount of miss_point and miss_peak increases more than the number of the hits, because of the stronger peak influence in the averaging. Precisely test results are as follows: 1939 black and white peaks, corresponding to a noise component of 3%, were introduced to the image "Lena". 11 peaks are classified correctly by the outlier method with a 3x3 filter mask and a threshold value of. 11 pixel are classified wrongly resulting in a 9.93% hit/miss rate. An application of the same test and analysis on the "Corvette" image with 73 noisy points (3% impulse noise) is producing following results: with the 3x3 outlier method and threshold of 593 pixel are not recognised or wrongly marked and 15 are correctly classified as noise. Thus the hit / miss rate amounts.77%. Through higher threshold value of 13 the amount of mismatched points falls onto 1571 points. On the other hand only 13 peaks can be correctly classified, so a better.1% hit rate can be achieved. It becomes clear that an increase of the threshold value can essentially enhance the hit / miss rate. However if the threshold is too high, the number of the hits falls so considerably that the opposite effect occurs. All in all the
outlier method, Ampli. 55 (Corvette) outlier method, Ampli. (Corvette) 1 13 9 5 1 1 13 9 5 1-1 - - - - Figure 3: Smoothing results of the outlier method (Corvette) high hit rates of the picture "Lena" can not be reached. One of the reasons for this mismatching is the high detail complexity of the "Corvette" image. These details affect the averaging and result in blurred edges. The application of the outlier method can not be recommended. Figure 3 shows the results of the test on the image "Corvette". Further there is a large difference between the recognition of black peaks (%-7%) and the recognition of white peaks (about %). One of the reasons for this behaviour can be found in the histograms of the test images. The image "Corvette" consists of many bright grey levels, so it is difficult to identify white peaks. But if a lower threshold value is chosen many non noisy points can be marked as peaks. Thus, the hit/miss rate is only inessential larger. The grey levels of the image "Lena" are in the middle of the histogram, so white and black peaks can be identified with approximately the same probability. An increase of the filter window size e.g. 9x9 amplifies the edge detecting properties of the outlier filter and many points are mismatched. Summarising the outlier method can reach high hit/miss rate, if following constraints are fulfilled: small deviation the mean grey level of the image is in the middle of the available grey range. a low degree of details. This can be estimated by analysing high frequencies in the amplitude spectrum. 3. Ranking method Another possibility for noise removal is the ranking method. The pixels within the filter window are sorted and the value of the pixel being processing is replaced by a certain element of the sorted sequence. The best known ranking filter is the median filter. The center window pixel is replaced by the median of the sorted sequence []. The advantages of the rank order method are: it is easy to implement, noise is removed without significantly affecting the sharpness of edges and of fine image details. Furthermore no new colour values are introduced. Disadvantages of the median filter are the amount of work required and particular image details and geometric structures such as thin horizontal or vertical lines are removed []. The right choice of the filter window size is one deciding factor for the quality of impulse removal. In case of a small, inhomogeneous 3x3 environment without noisy points there is a large probability, that a pixel is wrongly marked as peak.
ranking method (Lena) 1 9 7 5 3 1 1 3 5 7 9 1 1 9 7 5 3 1 ranking method (Corvette) 1 3 5 7 9 1 Amplitude Amplitude 55 Figure : Dependency of the ranking method hit rate from the impulse noise component: for the images Lena and Corvette Thus, majority of one specific colour is usually not available so there is no identification basis for outliers. Therefore edge or detail pixel are wrongly marked as peaks and removed. This pixel majority is usually given in larger filter windows, e.g. 9x9. Furthermore from certain noise component on a noisy point can be found in many neighbourhoods. This guarantees a correct peak classification. Otherwise the same problems as in 3x3 case can occur and the image edges and details can be blurred. Further research is necessary in order to determinate thresholds, which could help by the automatic selection of the filter attributes. For the following test sequences a 9x9 filter window is used. Figure shows the dependency of the ranking method smoothing results and the amount of impulse noise in the image. The hit rate for the Lena image amounts about %, if impulse noise component of.5% is introduced to it. A further increase of the noise component leads to even higher, up to 9%, hit rates. On the other hand impulse noise components lower than % produce the opposite effect: the influence of the image structures is essential for the smoothing process and many edge and detail points are wrongly marked as peaks. Thus the hit / miss rate falls clearly. An application of the ranking method on the original, noise free Lena image using a 9x9 filter neighbourhood delivers 13 wrongly marked points, which are usually edge points. This corresponds to 1.53% of all image points. In order to reduce this amount real peaks in the processed 9x9 neighbourhood are necessary. This can be confirmed by introducing of a 1.5% noise component into the image. The hit / miss rate amounts 5%. A further increase of the impulse noise component (more than 5%) reduces the influence of the image structures and a higher hit rate can be achieved. The disturbing influence of the image structures on the smoothing process is even clearer in case of the image Corvette. In the original, noise free image 931 pixels, corresponding to 3.13% from all image points, are marked as peaks and replaced. Figure shows the smoothing results of the ranking method and variable noise component in the image Corvette. If.5% of the pixels are noisy points a hit rate of approximately 55% (for dark peaks) and % (for bright peaks) can be achieved. In contrast to the image Lena for an acceptable % rate a higher impulse noise component is needed, because of the large amount of image details.
1 9 7 5 3 1 Impulse noise (Lena) 1 3 5 7 9 1 Outlier () Ranking 1 9 7 5 3 1 Impulse noise (Corvette) 1 3 5 7 9 1 Outlier (1) Ranking Figure 5: Comparison of the hit/miss rates of the outlier and of the ranking method on the images Lena and Corvette The maximum reachable hit / miss rate of the ranking method depends essentially on the distribution and clearness of the image details represented by the amount of high frequencies in the amplitude spectrum. The hit miss rate is largely independent from the expectation value of the image, if this is not near the borders of the available colour range. The deviation has no significant influence on the smoothing process.. Comparison of the outlier and the ranking method Figure 5 shows the noise removal results of the outlier and of the ranking method depending on the impulse noise component in the image. If the noise component is less than 7%, the outlier method delivers better results, in particular for noise percentage bellow 3%. In this case the ranking method is more sensitive for small details in the filter window than the outlier method. In case of a larger noise component (>7%) more peaks are found in a n n filter window, so the averaging process of the outlier method are affected. Noise components larger than 15% are resulting into 35% difference between the achieved hit/miss rates. On the other hand the influence of the image details is decreasing and the rank order method reaches hit rates of more than 9%. An important problem of the outlier method is the choice of a suitable threshold value. Different thresholds must be tested in order to select the value that delivers the best compromise between the number of correctly recognised peaks and the number of mismatched image points. Many edge points can be classified as peaks resulting in a low hit / miss rate. A fully automatic detection of the most suitable method for impulse noise cleaning is not possible with these simple tools. But these clues can be used as a first orientation in the noise cleaning process: For a noise component less than 7% the application of the outlier method is suitable. If the noise percentage is larger than 7% the ranking method should be applied. For images containing a lot of details the noise component threshold value for the applying of the ranking method must be decreased. The high detail degree of an image can be determinated on the amplitude spectrum of the image. With the outlier method the identification of peaks is difficult, if the average grey level of the image is near the ends of the grey range. In this case the ranking method should be used.
5. Applicability of the proposed methods This analysis and comparison of standard noise removal operators is only a first step for automatic determination of appropriate smoothing filters. The desired goal of our research is the creation of a knowledge base with available noise removal filters, which are characterised by a set of defined comparable, common features are proposed, like percentage of the noise component in the image, detail degree and colour distribution in the image histogram. These features must be extracted from every noisy image and matched with the patterns in the knowledge base, so the most suitable filter for a given noisy image can be chosen. Efficient and reliable methods for determination of the noise kind and noise component of the image as well as algorithms for analysis of the details must be developed and tested in practice. Furthermore, the shown analyses must be performed for other noise removal operators. Another important aspect is the analysis of white noise in order to find the most suitable cleaning filter and to determinate the setting parameters. The noise distribution curve can be compared with known probability distributions by an amount of extracted attributes. In a first attempt satisfying results by three of ten noise distributions types were achieved. Six further types can be recognised, if the noise parameters are in a certain range. For recognising of these white noise types new features must be defined and tested. This is a part of the future work. Similar methods can be developed for other image pre-processing fields like e.g. edge detection or image segmentation.. Conclusions In this paper two standard methods for impulse noise removal were compared. In particular the dependency of the smoothing results on the noise component in the image, the detail degree, the mean colour value, on the deviation and on the colour distribution were examined. The automatic determination of a suitable noise cleaning filter is not yet possible with these simple tools. But some advice for the choice of an appropriate smoothing operator can be given. Future work includes the comparison of other impulse noise removal methods and the integration of further noise attributes like texture etc. The analysis of white noise and extraction of similar features is another important aspect of our research. References [1] S. Diener. Noise analysis for medical images. Master thesis, 199, Department of Computer Science, TU Clausthal. [] O. Kao. New Impulse Noise Cleaning Methods for Monochrome and Colour Images (Ph. D. Thesis, TU Clausthal) Papierflieger (Clausthal-Zellerfeld), 1997. [3] T. Lehmann, W. Oberschelp, E. Pelikan, R. Repges. Image processing for medical images. Springer-Verlag (Berlin, Heidelberg, New York), 1997. [] W.K. Pratt. Digital Image Processing. John Wiley and Sons, Inc, 1991. [5] J.W. Tukey, Exploratory data analysis, Addison-Wesley, Reading, MA., 1971 [] M. Gabbouj, E. Coyle, N.C. Gallagher Jr. Overview of median and stack filtering. Circuits Systems Signal Processing,11(1):7-5,199