HOME

TheInfoList



OR:

In
mathematical morphology Mathematical morphology (MM) is a theory and technique for the analysis and processing of Geometry, geometrical structures, based on set theory, lattice theory, topology, and random functions. MM is most commonly applied to digital images, but it ...
and
digital image processing Digital image processing is the use of a digital computer to process digital images through an algorithm. As a subcategory or field of digital signal processing, digital image processing has many advantages over analog image processing. It allo ...
, a top-hat transform is an operation that extracts small elements and details from given
image An image or picture is a visual representation. An image can be Two-dimensional space, two-dimensional, such as a drawing, painting, or photograph, or Three-dimensional space, three-dimensional, such as a carving or sculpture. Images may be di ...
s. There exist two types of top-hat transform: the ''white top-hat transform'' is defined as the difference between the input image and its
opening Opening may refer to: Types of openings * Hole * A title sequence or opening credits * Grand opening of a business or other institution * Inauguration * Keynote * Opening sentence * Opening sequence * Opening statement, a beginning statemen ...
by some
structuring element In mathematical morphology, a structuring element is a shape, used to probe or interact with a given image, with the purpose of drawing conclusions on how this shape fits or misses the shapes in the image. It is typically used in morphological oper ...
, while the ''black top-hat transform'' is defined dually as the difference between the
closing Closing may refer to: Business and law * Closing (law), a closing argument, a summation * Closing (real estate), the final step in executing a real estate transaction * Closing (sales), the process of making a sale * Closing a business, the proc ...
and the input image. Top-hat transforms are used for various image processing tasks, such as
feature extraction Feature may refer to: Computing * Feature recognition, could be a hole, pocket, or notch * Feature (computer vision), could be an edge, corner or blob * Feature (machine learning), in statistics: individual measurable properties of the phenome ...
, background equalization,
image enhancement Image editing encompasses the processes of altering images, whether they are digital photographs, traditional photo-chemical photographs, or illustrations. Traditional analog image editing is known as photo retouching, using tools such as an ...
, and others.


Mathematical definitions

Let f:E\mapsto \mathbb be a
grayscale In digital photography, computer-generated imagery, and colorimetry, a greyscale (more common in Commonwealth English) or grayscale (more common in American English) image is one in which the value of each pixel is a single sample (signal), s ...
image, mapping points from a
Euclidean space Euclidean space is the fundamental space of geometry, intended to represent physical space. Originally, in Euclid's ''Elements'', it was the three-dimensional space of Euclidean geometry, but in modern mathematics there are ''Euclidean spaces ...
or discrete
grid Grid, The Grid, or GRID may refer to: Space partitioning * Regular grid, a tessellation of space with translational symmetry, typically formed from parallelograms or higher-dimensional analogs ** Grid graph, a graph structure with nodes connec ...
''E'' (such as \mathbb^2 or \mathbb^2) into the real line. Let b(x) be a structuring element of grayscale. Then, the white top-hat transform of ''f'' is given by: :T_w(f)=f-f \circ b, where \circ denotes the opening operation. The black top-hat transform of ''f'' (sometimes called the ''bottom-hat'' transform ) is given by: :T_b(f)=f\bullet b-f, where \bullet is the closing operation.


Properties

The white top-hat transform returns an image, containing those "objects" or "elements" of an input image that: * Are "smaller" than the structuring element (i.e., places where the structuring element does not fit in), and * are brighter than their surroundings. The black top-hat returns an image, containing the "objects" or "elements" that: * Are "smaller" than the structuring element, and * are darker than their surroundings. The size, or width, of the elements that are extracted by the top-hat transforms can be controlled by the choice of the structuring element b. The bigger the latter, the larger the elements extracted. Both top-hat transforms are images that contain only non-negative values at all pixels. One of its most important uses in
image segmentation In digital image processing and computer vision, image segmentation is the process of partitioning a digital image into multiple image segments, also known as image regions or image objects (Set (mathematics), sets of pixels). The goal of segmen ...
is to adjust nonuniform lighting conditions on an image and provide a better threshold value for separating objects.


Example

Assume that the user is only interested in small blobs on the image and wants to remove the larger bright objects. In this case, the white top-hat transform can remove larger bright objects and retain small blobs by selecting the size of the
structuring element In mathematical morphology, a structuring element is a shape, used to probe or interact with a given image, with the purpose of drawing conclusions on how this shape fits or misses the shapes in the image. It is typically used in morphological oper ...
that is between removed objects and objects of interest. The radius of six largest bright objects are approximately 50 to 100 pixels whereas the radius of objects of interest are around 2 to 4 pixels. In addition, the objects of interest are circular shapes so we choose a disk shaped structuring element with radius 5. However, selecting different shapes and sizes for the structuring element result in different images depending on whether objects fit in the structuring element or not. The other example is an image under nonuniform illumination, where the user wants to extract objects separately from background. The common method for image segmentation is to threshold the input image based on intensity value. However, if the image is under nonuniform lighting, it is possible that segmentation errors might present themselves since some objects in darker area have close intensity values as background intensity values and would not be extracted by only utilizing threshold method. In this case, before
Otsu's method In computer vision and image processing, Otsu's method, named after , is used to perform automatic image thresholding (image processing), thresholding. In the simplest form, the algorithm returns a single intensity threshold that separate pixels ...
is applied to input image, white top-hat transform should be implemented to correct nonuniform lighting condition and make obvious contrast between background and objects. Therefore, the objects can be extracted entirely from background without segmentation errors. The threshold values are 0.5216 and 0.2 and normalized to ,1/math> for original image and applied white top-hat transform respectively.


References

* ''Image Analysis and Mathematical Morphology'' by Jean Serra, (1982) * ''Image Analysis and Mathematical Morphology, Volume 2: Theoretical Advances'' by Jean Serra, (1988) * ''An Introduction to Morphological Image Processing'' by Edward R. Dougherty, (1992) * ''Hands-on Morphological Image Processing'' by Edward R. Dougherty and R. Lotufo, (2003) * ''Digital Image Processing'' (''Third Edition'') by Rafael C. Gonzalez and Richard E. Woods, {{ISBN, 978-93-325-7032-0(2008) Mathematical morphology Digital geometry