Parent Topic: Filter

Mode Filter

The mode filter is primarily used to clean up thematic maps for presentation purposes, in that it replaces small "island" themes by their larger, surrounding themes.

The mode filter computes the mode of the grey level values (the most frequently occurring grey level value) within the filter window surrounding each pixel.

The minimum filter size is 1 by 3, and the maximum filter size allowed is 7 by 7. The filter window does not need to be square.

Example:

   5 3 3 
   3 5 3     3x3 filter window
   3 4 5
Filtered pixel of filter window (3,3,3,3,3,4,5,5,5) is 3, (which occurs 5 times).

NOTE: In order to filter pixels located near the edges of the image, edge pixel values are replicated to give sufficient data.

It is possible that a decision may have to be made between 2 values with the same frequency of occurrence. In this case, if the center value is one of the tie values, it is chosen. Otherwise, the first tie value encountered is chosen.

Example:

   1 5 3 
   3 2 3     3x3 filter window
   5 4 5
Filtered pixel of filter window (1,5,3,3,2,3,5,4,5) is set to 5. Pixel 3 occurs 3 times and pixel 5 occurs 3 times. Neither 3 nor 5 is in the center position. The 5 in the top row is encountered first as the values are read, so it is chosen as the mode value.

NOTE: The EASI/PACE FMO program also performs mode filtering. In the FMO program, there are additional parameters that the user can specify. Due to the different technique in performing mode filtering in ImageWorks and the FMO program, the result of the filtered image may be slightly different when comparing the two results.


Parent Topic: Filter
About PCI Help Gateway