Top Hat by Reconstruction: binary case

As the top hat is defined for the algebraic opening, there are a large variety of top hat operators that can be designed by using other openings.

A particularly useful opening for use in the top hat is the opening by reconstruction from a marker f:

displaymath110

The top hat in this case is given by:

displaymath111

where m is the marker used in the reconstruction. The selection of the marker is a crucial part of the segmentation process using this top hat operator.

Segmenting the holes of a PCB

The goal of this example to illustrate the binary top hat using a reconstruction to identify and extract the holes of the PCB image.

Below we see the original image and the marker used in this experiment. The marker is a one-width pixel frame image, i.e., a constant image with value 0, and the border pixels with value 255.

a)original; b)marker: a one-width pixel frame
a) b)

The reconstruction from the frame marker recovers all the connected components connected to the "frame" image, thus leaving out the holes. The top hat thus recovers the unconnected components, which are the PCB holes in this example. Both images can be seen below.

a)binary reconstruction of the marker conditioning to the original; b)top-hat
a) b)

Note that there are small dots that were recognized as holes and holes that were not segmented. The small dots can be explained due to the noise in the copper part of the image. There are small holes in the tracks of the PCB due to noise. The undetected holes are due to PCB imperfection and/or noise. These holes are connected to the frame as they are not closed holes.





BRAZILIAN WORKSHOP'97 ON MATHEMATICAL MORPHOLOGY