Digital Filters
What are they? Local operation (neighborhood operation in GIS terminology) by mask, window, or kernel (different words for the same thing). Also called “convolution”!
Purposes (1) Image improvement or restoration Elimination of problems with lines and/or points (ie. filling in gaps) Noise suppression Image enhancement (sharpening) Edge detection of linear structures.
Purposes (2) Preprocessing before classification Averaging of field units Elimination of local disturbances. Discover spatial patterns (enhancement) Better distinguish area, line, and point objects.
Overall…. Trying to enhance low frequency detail (averaging), high frequency detail (sharpening), and edges (areas of rapid change). All about, as always, reflectance values.
The size of the neighborhood convolution mask or kernel (n) is usually 3 x 3, 5 x 5, 7 x 7, or 9 x 9. We will constrain our discussion to 3 x 3 convolution masks with nine coefficients, ci, defined at the following locations: c1 c2 c3 Mask template = c4 c5 c6 c7 c8 c9
Mean filter. The coefficients, c1, in the mask are multiplied by the following individual brightness values (BVi) in the input image – and then divided by 9 (thereby creating some sort of an average): c1 x BV1 c2 x BV2 c3 x BV3 Mask template = c4 x BV4 c5 x BV5 c6 x BV6 c7 x BV7 c8 x BV8 c9 x BV9
Low frequency (pass) filter: block the high spatial frequency detail, left the low-frequency A kernel with small positive values with the same or a little large central value High frequency (pass) filter: remove the slowly varying components and enhance the high- frequency local variations. a kernel with a high central value, typically surrounded by negative weights 1 1 1 1 1 1 .25 .5 .25 1 1 1 1 2 1 .5 1 .5 1 1 1 1 1 1 .25 .5 .25 a b c -1 -1 -1 1 -2 1 -1 9 -1 -2 5 -2 -1 -1 -1 1 -2 1 e d
Linear edge enhancement Directional Laplacian Highlight points, lines, edges, suppress uniform and smooth regions -1 0 1 -1 -1 -1 0 0 0 1 1 1 0 1 1 -1 0 1 -1 -1 0 1 1 0 1 0 -1 0 -1 -1 Vertical edges Horizontal edge NW-SE NE-SW directional 0 -1 0 -1 4 -1 0 -1 0 -1 -1 -1 -1 8 -1 1 -2 1 -2 4 -2 1 -2 1 Laplacian
Can also do, say, a median or modal (median below, 3x3 and 5x5) filter
Another median filter example.
Review: Properties of filters Low pass: averaging small fluctuations in image values. Random noise suppression. Smoothing. However, image blurs. High pass: enhancing details (and noise). Emphasizes edges.