Symmetric Nearest Neighbor

from Wikipedia, the free encyclopedia
Picture left before, right after the application of the SNN filter

Symmetric Nearest Neighbor ( SNN ) is a filter method that is used in image processing to remove noise .

- 0- + -
-0 00 +0
- + 0+ ++

The procedure works as follows:

  1. In the eighth neighborhood (i.e. the eight pixels that are directly adjacent to a certain pixel) of a pixel - here denoted by 00 - the neighboring pixels that are opposite each other are considered as a pixel pair (there are therefore the pairs - - / ++, 0- / 0 +, + - / - + and -0 / + 0).
  2. The pixel that is most similar in color to the middle pixel 00 is now selected from each of the four pairs - that is, four pixels remain.
  3. A mean value is now formed from the color values ​​of these four pixels . This new color value is assigned to the middle pixel (00).
  4. This process is repeated so that each pixel of the image is used once as the "middle" pixel.

In this way, the image is "smoothed" and individual pixels that do not fit into the environment are adjusted. However, this makes the picture a bit blurred overall.