Filter
The
concept of filtering involves
neighborhood operations work with the values of the image pixels in the
neighborhood and the corresponding values of a sub image that has the
same dimensions as the neighborhood.
The Filter
operation can be
classified as:
Edge
Filter
Local discontinuities in
image luminance from one level to another are
called
luminance edges, limited to image amplitude discontinuities between
reasonably smooth
regions.
There are two major classes of differential edge detection: first- and
second-order
derivative. For the first-order class, some form of spatial first-order
differentiation is
performed, and the resulting edge gradient is compared to a threshold
value. An
edge is judged present if the gradient exceeds the threshold. For the
second-order
derivative class of differential edge detection, an edge is judged
present if there is a
significant spatial change in the polarity of the second derivative.
- Sobel: The Sobel
operator edge detector where the mask values of
the north, south, east, and west pixels are doubled. The motivation for
this weighting is to give equal importance to each pixel in terms of
its contribution to the spatial gradient.
- Roberts: Diagonal edge
gradients can be obtained by forming
running differences of diagonal
pairs of pixels. This is the basis of the Roberts cross-difference
operator:
Smoothing Spatial Filters
Smoothing filters are used
for blurring and for noise reduction.
Blurring is used
in preprocessing steps, such as removal of small details from an image
prior to
(large) object extraction, and bridging of small gaps in lines or
curves. Noise
reduction can be accomplished by blurring with a linear filter and also
by nonlinear
filtering.
- Mean: The output of a
mean, linear spatial filter is simply the
average
of the pixels contained in the neighborhood of the filter mask. These
filters
sometimes are called averaging filters or lowpass filters.
A major use of averaging filters is in the reduction of
“irrelevant” detail in an
image. By “irrelevant” we mean pixel regions that are small
with respect to the
size of the filter mask.
- Mode: The Mode filter is
used to remove noise from an image by
replacing pixels with the most frequently occurring pixel value
selected from a certain window size.
- Median: A median filter,
which, as its name implies, replaces the
value of a pixel by the
median of the gray levels in the neighborhood of that pixel (the
original value
of the pixel is included in the computation of the median). Median
filters are
quite popular because, for certain types of random noise, they provide
excellent
noise-reduction capabilities, with considerably less blurring than
linear
smoothing filters of similar size.
Morphological Filters
Morphological image
processing is a type of processing in which the
spatial form or
structure of objects within an image are modified. Dilation and erosion
are three fundamental morphological operations.
- Dilation: With dilation,
an object grows uniformly in spatial
extent, whereas with erosion an object shrinks uniformly.
- Erosion: With erosion an object
shrinks uniformly.
It is
accessible through:
PROCESSING → RASTER PROCESSING
→ FILTER...
Selection
of the layer to apply the filter
- On the Layer field select the raster layer to apply the filter.
- Select the Type of filter to
be used. Depending on the selected type different and additional parameters field will appear below, e.g., if a morphological filter is selected another parameter (Morph Type) appears and proper value should be setup.
- Set the number of iterations.
- In Bands select the
desired bands to be processed.
- Check in the Preview box to activate visualization of operation and click on the New ROI button to draw the area to be used by the filter operation.
If the
user check in the User Mask Definition box, it is
allowed to define information about the mask being used.
- Size: size of
the mask
- Default Value: default value used in the mask.
- The
tool shows a empty component that allows
the definition of a mask with a size defined by the user.
- The
tool shows a component with
previous mask defined by the user.
Output
information
- Repository -
Select one type of repository by
clicking on the
button to save the output layer as a file or on the
button to save it in the database.
- Layer Name - inform
the raster name.
- Press the OK button
to save the resulting raster with filter.
Hint: The filtered image will be added as a new layer at the
TerraView project.
Hint: Although the user can change the layer by selecting in the Layer Explorer, it does not change the layer selected in a open filter interface.