Abstract:
A system and method for removing impulsive noise from a digital signal are disclosed. The system and method determines either a neighborhood maximum and/or a neighborhood minimum for a pixel of interest. The intensity of the pixel of interest is then compared to the neighborhood maximum or the neighborhood minimum to determine whether the pixel of interest should be replaced.

Description:
CROSS REFERENCE TO RELATED APPLICATIONS  
       [0001]     This application claims priority from U.S. provisional application No. 60/578,066 filed on Jun. 9, 2004, and titled “Impulsive Noise Removal Using Maximum and Minimum Neighborhood Values” which is incorporated by reference herein in its entirety. 
     
    
     FIELD OF THE INVENTION  
       [0002]     The present invention relates generally to signal processing and in particular to the compression of digital images and video. More specifically, the present invention relates to a system and method for removing impulsive noise using maximum and minimum neighborhood values.  
       BACKGROUND OF THE INVENTION  
       [0003]     Digital video products and services and devices for storage and retrieval of video streams on the Internet are ubiquitous in the marketplace. Due to limitations in digital signal storage capacity and limitations in network and broadcast bandwidth, compression of digital video signals is essential to digital video storage and transmission. As a result, many standards for compression and encoding of digital video signals, such as MPEG-2 and MPEG-4, have been promulgated. These standards specify with particularity the form of encoded digital video signals and how such signals are to be decoded for presentation to a viewer.  
         [0004]     Video preprocessing techniques may be applied to incoming digital video signals so that the signals may be more efficiently compressed by subsequent video compression circuitry. For example, a preprocessor may detect noise in a frame and reduce or remove the noise in the frame before transmitting the frame to the video compression circuitry. Removing noise from digital video signals is not only important for improving the visual quality of the signal, but also for increasing the efficiency of the MPEG video encoders.  
         [0005]     Various noise artifacts associated with digital video signals are known in the art. Impulsive noise, also known as salt-and-pepper noise, is defined as individual pixels whose intensity values are much larger or smaller than that of its surrounding neighbors. Often, these impulsive pixels are the result of some type of error or noise and require correction and/or concealment. In some instances, even if the pixel of interest correctly represents the true intensity of a given location at a particular point of time, it is still desirable to treat the impulsive pixel as noise. An example of this is in digital images and video where high frequency content, which includes impulsive pixels, is not only very distracting to a viewer but also very difficult for compression algorithms to effectively compress. The use of bits to compress these impulses takes away bandwidth that could be used more effectively on other parts of the picture. For this reason, a variety of algorithms have been developed in the prior art to reduce and/or remove impulsive noise.  
         [0006]     A popular approach to impulsive noise removal is disclosed in “Digital Image Processing” by R. C. Gonzalez and R. E. Woods, Addison_Wesley Publishing Company, 1992, pp. 191-195. Gonzalez and Woods describe a median filter where the median of a set of local neighborhood values is calculated and may be used (adaptively or nonadaptively) to replace the pixel of interest. The median is a value that is both (a) less than half the values in the set and (b) greater than half the values in the set. Referring now to  FIG. 5 , there is shown an example of neighborhood data where the pixel with intensity value of 99 is the pixel of interest. As an example of median filtering, the 3×5 pixel neighborhood data shown in  FIG. 5  contains the values: 
        (10, 15, 10, 12, 20, 15, 10, 99, 18, 10, 12, 15, 10, 20, 18).        
 
         [0008]     Sorting these values results in: 
        (10, 10, 10, 10, 10, 12, 12, 15, 15, 15, 18, 18, 20, 20, 99).        
 
         [0010]     Therefore, a median filter would use the value of 15 to replace the impulsive value of 99 at the pixel of interest in the center.  
         [0011]     One disadvantage of median filtering for both hardware and software implementations is that the calculation of the median requires the neighborhood values to first be sorted. Sorting algorithms not only require computational resources (approximately N*log 2  N operations to sort N elements) but may also require additional resources such as memory and code space. Therefore, it is desirable to have a system and method for impulsive noise removal that reduces the necessary computations, thereby resulting in a faster and more efficient method for impulsive removal.  
         [0012]     Further limitations and disadvantages of conventional and traditional approaches will become apparent to one of skill in the art through comparison of such systems with the present invention as set forth in the remainder of the present application with reference to the drawings.  
       SUMMARY OF THE INVENTION  
       [0013]     According to the present invention, these objects are achieved by a system and method as defined in the claims. The dependent claims define advantageous and preferred embodiments of the present invention.  
         [0014]     A system and method for removing impulsive noise from a digital signal using the maximum and minimum values in a local neighborhood are disclosed. The methodology described in the present invention differs from the well-known method of using a median filter for impulsive noise removal by using the maximum and minimum operators instead of the median operator. These operations greatly reduce the computations necessary for each pixel, which is a significant factor for many hardware and software implementations. Thus, the principles of the present invention advantageously reduces and/or removes impulsive pixels regardless of their origin.  
         [0015]     In one aspect, the present invention processes a video signal comprising a sequence of frames, each of which further comprises a plurality of pixels. The present invention determines a neighborhood maximum or a neighborhood minimum for a pixel of interest, and compares the intensity of the pixel of interest to the neighborhood maximum or the neighborhood minimum to determine whether the pixel of interest should be replaced. The pixel of interest is replaced with a minimum replacement value if the intensity of the pixel of interest is less than the neighborhood minimum. In one embodiment, the minimum replacement value is the neighborhood minimum. The pixel of interest is replaced with a maximum replacement value if the intensity of the pixel of interest is greater than the neighborhood maximum. In one embodiment, the maximum replacement value is the neighborhood maximum.  
         [0016]     In another aspect, the present invention compares the sum of the intensity of the pixel of interest and a LOW_OFFSET to the neighborhood minimum. The pixel of interest is then replaced with a minimum replacement value if the sum of the intensity of the pixel of interest and the LOW_OFFSET is less than the neighborhood minimum. In one embodiment, the minimum replacement value is the neighborhood minimum. The present invention may also compare the intensity of the pixel of interest to the sum of a HIGH_OFFSET and the neighborhood maximum. The pixel of interest is then replaced with a maximum replacement value if the intensity of the pixel of interest is greater than the sum of the HIGH_OFFSET and the neighborhood maximum. In one embodiment, the maximum replacement value is the neighborhood maximum.  
         [0017]     In calculating the neighborhood maximum or the neighborhood minimum for one embodiment of the present invention, the neighborhood does not include the pixel of interest. Additionally, the size of the neighborhood for calculating the neighborhood maximum or the neighborhood minimum may be as large or as small as desired. For example, a neighborhood may be an M×N neighborhood or a non-rectangular shaped neighborhood. The neighborhood may also be an adjustable neighborhood in which the size and/or shape of the neighborhood may be adjusted based on some metric or set of criteria. For example, in one embodiment, the size of the neighborhood may be adjusted for pixels lying on the boundary.  
         [0018]     These and other advantages, aspects and novel features of the present invention, as well as details of an illustrated embodiment thereof, will be more fully understood from the following description and drawings. 
     
    
     BRIEF DESCRIPTION OF SEVERAL VIEWS OF THE DRAWINGS  
       [0019]     The accompanying drawings, which are incorporated herein and form a part of the specification, illustrate the present invention and, together with the description, further serve to explain the principles of the invention and to enable a person skilled in the pertinent art to make and use the invention.  
         [0020]      FIG. 1  illustrates a block diagram of an MPEG video preprocessor in accordance with one embodiment of the present invention.  
         [0021]      FIG. 2  illustrates a block diagram of an impulse filter in accordance with one embodiment of the present invention.  
         [0022]      FIG. 3  is a flow chart illustrating the steps of an impulse filter in accordance with one embodiment of the present invention.  
         [0023]      FIG. 4  is a flow chart illustrating the steps of an impulse filter in accordance with another embodiment of the present invention.  
         [0024]      FIG. 5  illustrates a block diagram of an example of neighborhood data where the pixel with intensity value of 99 is the pixel of interest. 
     
    
     DETAILED DESCRIPTION OF THE INVENTION  
       [0025]     The present invention will now be described in detail with reference to a few preferred embodiments thereof as illustrated in the accompanying drawings. In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present invention. It will be apparent, however, to one skilled in the art that the detailed description given herein is for explanatory purposes as the invention extends beyond these limited embodiments and that the present invention may be practiced without some or all of these specific details. In other instances, well known processes and steps have not been described in detail in order not to unnecessarily obscure the present invention.  
         [0026]     Referring now to  FIG. 1 , there is shown a block diagram of an MPEG video preprocessor in accordance with one embodiment of the present invention. The video preprocessor implements an impulse filter as described in the present invention to condition a digital video signal for better compression by an MPEG video encoder by removing unwanted or irrelevant picture information such as random noise. In accordance with a preferred embodiment of the present invention, the MPEG video preprocessor receives digital video and outputs conditioned digital video intended for compression by an MPEG video encoder, such as by the BCM7042 MPEG-2 Video/Audio Encoder, produced by Broadcom Corporation, located in Irvine, Calif. In another embodiment, the video preprocessor may be integrated into an encoder such as the BCM7042.  
         [0027]     An overview of the dataflow and buffers for an impulse filter in accordance with one embodiment of the present invention is shown in  FIG. 2 .  FIG. 2  illustrates an impulse filter  200 , a buffer  202  coupled to the input of the impulse filter  200 , and memory  204  coupled to the output of the impulse filter  200 . One skilled in the art will realize that the outputted digital signal does not necessarily need to be transferred directly to a memory  204 , but may be transferred to another module such as an MPEG encoder, a hard drive, and the like.  
         [0028]     In one aspect, impulsive noise reduction of the present invention is generally performed by first computing the minimum and maximum values in the neighborhood. In one embodiment, this definition of neighborhood does not include the pixel of interest. Therefore, there will be N−1 elements in this neighborhood and computing the neighborhood minimum and maximum will require 2*(N−2) total comparisons. Referring now to  FIG. 5 , there is shown an example of neighborhood data. As defined here, X represents the intensity value of the pixel of interest and LOCALMIN and LOCALMAX represent the neighborhood minimum and maximum, respectively. The pixel of interest is classified as an impulsive pixel and replaced only in these two scenarios:  
         [0029]     1. Its intensity is less than the local minimum, i.e. X&lt;LOCALMIN.  
         [0030]     2. Its intensity is greater than the local maximum, i.e. X&gt;LOCALMAX.  
         [0031]     Thus, referring to the example data in  FIG. 5 , X, LOCALMIN and LOCALMAX would be equal to 99, 10 and 20, respectively, and LOCALMAX (with the value of 20) could be used to replace the pixel of interest.  
         [0032]     More specifically, referring now to  FIG. 3 , there is shown a flow chart illustrating the steps of an impulse filter in accordance with one embodiment of the present invention. At step  302 , the neighborhood minimum (LOCALMIN) for the current pixel of interest is calculated. At step  304 , the neighborhood maximum (LOCALMAX) for the current pixel of interest is calculated. The intensity of the current pixel of interest (X) is then compared to both values at steps  306  and  310 . If the intensity of the pixel of interest is less than LOCALMIN, then the intensity of the current pixel of interest is replaced with a minimum replacement value at step  308 . The minimum replacement value may be any intensity value used to replace pixels whose intensity is lower than LOCALMIN. In a preferred embodiment, the minimum replacement value is the LOCALMIN value. If the intensity of the pixel of interest is greater than the LOCALMAX, then the intensity of the current pixel of interest is replaced with a maximum replacement value at step  312 . The maximum replacement value may be any intensity value used to replace pixels whose intensity is greater than LOCALMAX. In a preferred embodiment, the maximum replacement value is the LOCALMAX value.  
         [0033]     One skilled in the art will realize that the present invention is not limited to this specific sequence of steps, but that the present invention may be practiced in any desirable sequence while still encompassing the principles underlying the present invention. For example, the present invention may be practiced by first calculating the LOCALMIN and then determining whether the intensity of the current pixel of interest is less than the LOCALMIN. If it is and the pixel of interest is replaced, then it may not be necessary to calculate the LOCALMAX or perform the subsequent LOCALMAX comparison.  
         [0034]     Moreover, the size of the neighborhood for calculating LOCALMIN and LOCALMAX is not constrained and may be as large or as small as desired. For example, in a preferred embodiment, a neighborhood may be an M×N neighborhood, such as 1×5 or 3×5 as illustrated in  FIG. 5 . Alternatively, the neighborhood may also be a non-rectangular shaped neighborhood. The neighborhood may also be an adjustable neighborhood in which the size and/or shape of the neighborhood may be adjusted based on some metric or set of criteria. For example, in one embodiment, the size of the neighborhood may be adjusted for pixels lying on the boundary.  
         [0035]     In another embodiment of the present invention, two offsets are defined that allow scalability of the impulse filter: LOW_OFFSET and HIGH_OFFSET. In this embodiment, the pixel of interest will then be replaced in only one of these scenarios:  
         [0036]     1. The sum of the pixel&#39;s intensity and the low offset is less than the local minimum, i.e. (X+LOW_OFFSET)&lt;LOCALMIN.  
         [0037]     2. The pixel&#39;s intensity is greater than the sum of the local maximum and the high offset, i.e. X&gt;(LOCALMAX+HIGH_OFFSET).  
         [0038]     Thus, setting LOW_OFFSET and HIGH_OFFSET both to zero result in the conditions described above with reference to  FIG. 3 . Increasing values of LOW_OFFSET and HIGH_OFFSET above zero will cause the conditions to be satisfied less frequently and thereby resulting in fewer pixels to be filtered.  
         [0039]     More specifically, when the intensity of the pixel of interest is greater than the maximum value of every other pixel in the neighborhood plus an adjustable offset, i.e., then the pixel of interest is replaced by the maximum pixel in the neighborhood. When the intensity of the pixel of interest is less than the minimum value of every other pixel in the neighborhood plus an adjustable offset, then the pixel of interest is replaced by the minimum pixel in the neighborhood.  
         [0040]     Referring now to  FIG. 4 , there is shown a flow chart illustrating the steps of an impulse filter in accordance with another embodiment of the present invention. At step  402 , the neighborhood minimum (LOCALMIN) for the current pixel of interest is calculated. At step  404 , the neighborhood maximum (LOCALMAX) for the current pixel of interest is calculated. The intensity of the current pixel of interest (X) is then compared to the LOCALMIN and a LOW_OFFSET. More specifically, at step  406 , the sum of the pixel&#39;s intensity of interest and the LOW_OFFSET are compared to the LOCALMIN. If this sum is less than the LOCALMIN, then the intensity of the current pixel of interest is replaced with a minimum replacement value at step  408 . The minimum replacement value may be any intensity value used to replace pixels whose sum of its intensity and a LOW_OFFEST is lower than LOCALMIN. In a preferred embodiment, the minimum replacement value is the LOCALMIN value.  
         [0041]     The intensity of the current pixel of interest (X) may then compared to the LOCALMAX and a HIGH_OFFSET. More specifically, at step  410 , the pixel&#39;s intensity of interest is compared to the sum of the LOCALMAX and the HIGH_OFFSET. If the pixel&#39;s intensity is greater than this sum, then the intensity of the current pixel of interest is replaced with a maximum replacement value at step  412 . The maximum replacement value may be any intensity value used to replace pixels whose intensity is greater than the sum of LOCALMAX and the HIGH_OFFSET. In a preferred embodiment, the maximum replacement value is the LOCALMAX value.  
         [0042]     As already described above, one skilled in the art will realize that the present invention is not limited to this specific sequence of steps, but that the present invention may be practiced in any desirable sequence while still encompassing the principles underlying the present invention. Moreover, the values of LOW_OFFSET and HIGH_OFFSET may be determined according to the requirements of processing. Additionally, the size of the neighborhood for calculating LOCALMIN and LOCALMAX is not constrained and may be as large or as small as desired. For example, in a preferred embodiment, a neighborhood may be an M×N neighborhood, such as 1×5 or 3×5 as illustrated in  FIG. 5 . Alternatively, the neighborhood may also be a non-rectangular shaped neighborhood. The neighborhood may also be an adjustable neighborhood in which the size and/or shape of the neighborhood may be adjusted based on some metric or set of criteria. For example, in one embodiment, the size of the neighborhood may be adjusted for pixels lying on the boundary.  
         [0043]     While the invention has been described with reference to certain embodiments, it will be understood by those skilled in the art that various changes may be made and equivalents may be substituted without departing from the scope of the invention. In addition, many modifications may be made to adapt a particular situation or material to the teachings of the invention without departing from its scope. For example, impulsive noise removal as disclosed in the present invention is often used to process digital images and video but the general concept could also be applied to other applications including one-dimensional and multi-dimensional signal processing. Therefore, it is intended that the invention not be limited to the particular embodiment disclosed, but that the invention will include all embodiments falling within the scope of the appended claims.