Image Processing Reference
In-Depth Information
where r l is the index vector of the grid (row and column indices for a matrix) of an
element, G , with G ( r l ) representing the value of the element. When F ( r k r l ) is
undefined for a given r k r l , e.g., because it is a point outside of an image, usually
an assumption such as that it is zero is made. The definition above has provisions
that morphological operations can be applied to the discrete gray image F . This is
because one can measure the local maximum and minimum after their elements are
modified due to a pointwise multiplication by G . However, we will refrain from
discussing gray images here to limit the scope only to images where both F as well
as G are binary. In all cases, the purpose of the neighborhood is twofold:
to mark the points that participate into max and min operations
to weight them within the allowed region
Some care should be taken when marking and computing the points of local images
because weighting with zero is not the same as excluding the point from the local
image, although this is normally what the user wishes.
Whether or not a zero of the filter is to be interpreted as a weight or a region
marker matters in morphological operations. For example, a weight of zero forces
the min operation to always produce zero on binary images, which consist of ones
and zeros, regardless of the other coefficients of the filter and even regardless the
input image, whereas interpreting the same zeros as region excluders would mean
that the corresponding points do not participate in min calculations. The zero co-
efficients of filters used under max, min thus behave differently in comparison to
filters used in summation operations of convolutions. This is because a sum does not
change, regardless of whether the zero coefficients are markers, or that the respective
image points participate to summation with the weight zero. To avoid the interpre-
tation ambiguities, it is practical to assume that the morphological filter coefficients
as markers rather than weights, i.e., a coefficient zero is a region-excluding marker,
whereas a coefficient one is a region-including marker.
What
really do to images becomes more intuitive when they are applied
to an image. Figure 17.1 shows a binary image F and a filter G , which is the filter
shown as G 3
and
in Eq. (17.3). The color code is such that blue represents 0 and red
represents 1.
For convenience we used light red and light blue colors in illustrations. They
represent 1 and 0, respectively, too, but they are chosen so to mark points that have
changed their values as compared to the original. As seen from these results, the
dilation operator dilates the image in a way that is consistent with the direction of
the filter. There is an enlargement of the objects, but it is systematically in the direc-
tion of the filter. There is no dilation of horizontal edges. The erosion filtering acts
analogously, but it reduces the objects. We can draw several conclusions from this:
1. Objects that are too close to each other are merged after a dilation, e.g., the letter
A and the dot “.” in the example.
2. If there is a dominant filter direction, then dilation has a directional preference
too, e.g., a horizontal filter dilates edges with horizontal direction.
3. Objects smaller than the filter disappear under erosion, e.g., the dot “.” in the
example.
Search WWH ::




Custom Search