Morphology fundamentals consist of erosion and dilation, which are basic morphological operations. Erosion removes pixels from object boundaries, shrinking object sizes and enlarging holes. Dilation adds pixels to boundaries, enlarging object sizes and shrinking holes. Both operations use a structuring element to determine how many pixels are added or removed. Erosion compares the structuring element to the image, removing pixels where it is not contained. Dilation compares overlaps, adding pixels where the structuring element and image overlap by at least one element.
2. Erosion And Dilation.
Morphology fundamentals consist of dilation and erosion. Which are the most basic
morphological operation.
Dilation adds pixels to the boundaries of objects in an image, while erosion removes pixels on
object boundaries.
The number of pixels added or removed from the objects in an image depends on the size and
shape of the structuring element used to process the image.
3. Erosion.
Erosion is one of the basic operators in the area of morphology, the other being dilation.
It is typically applied to binary images, but there are versions that work on grayscale images.
The basic effect of the operator on a binary image is to erode away the boundaries of regions of
foreground pixels (i.e. white pixels, typically).
Thus areas of foreground pixels shrink in size, and holes within those areas become larger.
4. How it works ?
In erosion operator takes two pieces of data as inputs. The first is the image which is to be
eroded.
The second is a (usually small) set of coordinate points known as a structuring element (also
known as a kernel).
It is this structuring element that determines the precise effect of the erosion on the input
image.
In mathematical term erosion is defined as- For image A and structuring element B in the Z^2,
erosion is defined as
5. This equation indicates that erosion of A by B is the set of all points Z such that B, translated
(shifted by z), is a subset of A i.e., B is entirely constant with A.
B is entirely contained within A. Erosion reduces the number of pixels from the object boundary.
The number of pixels removed depends on the size of structuring element.
•Fig Before and after erosion with structuring element.
6. Dilation.
Dilation is one of the basic operators in the area of morphology, the other being erosion. It is
typically applied to binary images, but there are versions that work on grayscale images.
The basic effect of the operator on a binary image is to gradually enlarge the boundaries of
regions of foreground pixels (i.e. white pixels, typically).
Thus areas of foreground pixels grow in size while holes within those regions become smaller.
The dilation operation usually uses a structuring element for probing and expanding the shapes
contained in the input image.
7. How it works ?
Dilation is a type of transformation that changes the size of the image. The scale factor,
sometimes called the scalar factor, measures how much larger or smaller the image is.
Below is a picture of each type of dilation (one that gets larger and one that gets smaller).
For e.g. The picture below shows a dilation with a scale factor of 2. This means that the image, A'
is twice as large as the pre-image A. Like other transformations, prime notation is used to
distinguish the image from the pre-image. The image always has a prime after the letter such as A'
.
8. Dilations can also reduce the size of shape. The picture below demonstrations a dilation of ½
Any time that the scale factor is a fraction, the image will get smaller
Reducing The Size.
9. The amount by which the image grows or shrinks is called the "Scale Factor". In
dilation, multiply the dimensions of the original by the scale factor to get the dimensions of the
image.
In dilation, the image and the original are similar, in that they are the same shape but not
necessarily the same size.
Dilation is defined as where A is the image and B is the
structuring element.
Hence dilation of A with B is a set of all displacement, Z , such that (B) and A overlap by at least
one element. Dilation adds pixel to the boundaries of objects in an image. The number of pixels
added depends on the shape size of the structuring element.
,