USING MARKERS TO SELECT FEATURES
The examples of Boolean logic shown above operate at the pixel level. At each
pixel location, the values in the two source images are compared and the result used
to determine the state of the pixel in the derived result, without any regard to any other
pixels in the image. For some purposes it is desirable to perform Boolean logic using
entire features. This makes it possible to have one image containing markers that identify
features of interest, with a second image containing the features themselves, to produce
a result in which the features that contain the markers are selected in their entirety.
An example of a Boolean feature-AND is shown in Figure 4.25. Originally a
color image, this confocal microscope image shows red cells, some of which contain
green nuclei. The challenge is to select those cells that contain the green nuclei as
markers. Thresholding the red and green channels, respectively, produces binary
images of the cells and the nuclei. Combining these with a pixel-based Boolean
AND would produce an image identical to Figure 4.25(d), which is just the marks
themselves. A feature-based AND using Figure 4.25(d) as the marker and Figure
4.25(b) as the target instead keeps the entire feature (the cell) if any part of it is
selected by the marker (the nucleus).
It is necessary to understand that in the feature-based AND, order is important.
A conventional pixel-based Boolean operation commutes (i.e., A AND B produces
the same result as B AND A), but the feature-based AND does not. There are several
different ways that this process can be implemented. Some systems use a dilation
method, in which the markers are dilated iteratively but only pixels selected by the
target image can be turned on. The method must be repeated until no further changes
occur, and for complex shapes this can take a long time. Another approach first
labels all of the features in both images, and if any pixel within a feature is selected
by a marker, the entire feature is kept.
The feature-based AND is an important tool, but there is no need for a feature-
based OR. That would produce exactly the same result as a pixel-based OR, keeping
any feature that was present in either image. A feature-based Ex-OR may be useful
in some instances (one is the disector used for stereological counting using two
parallel plane images), and may either be implemented directly or by combining a
feature-based AND with a pixel-based Ex-OR.
Regardless of the details of the implementation method, the feature-AND tech-
nique opens up many possibilities for selecting objects based on the presence of a
marker. The marker(s) may in some instances be a set of lines or points used to
probe the image, such as a grid or a set of outlines of regions present in the image.
Examples of this will be shown below. In many cases the marker is a feature within
the object itself, either usually a shape or color tag that can be separately identified.
For example, the image in Figure 4.26 shows some candies imaged with a desktop
flatbed scanner. Thresholding of the candies is most easily accomplished by selecting
the background pixels (a fairly uniform unsaturated grey) rather than the candies,
which vary in color. The resulting image has interior holes due to the reflections
from the shiny candy surface and the printed “m” characters, but these holes can be
filled as described previously. The resulting features touch, but are convex and easily
separated by a watershed segmentation.
2241_C04.fm Page 247 Thursday, April 28, 2005 10:29 AM
Copyright © 2005 CRC Press LLC