0% found this document useful (0 votes)
96 views25 pages

Morphological Operators Pv8

Morphological operations involve manipulating the shape and structure of objects in an image. They use small patterns called structuring elements to probe and modify images. Erosion removes pixels on object boundaries, shrinking objects. Dilation adds pixels to object boundaries, expanding objects. Opening performs erosion followed by dilation to smooth contours and close small holes. Closing performs dilation followed by erosion to smooth contours and fill small gaps. Together these operations can extract image components and remove imperfections.

Uploaded by

huachuhulk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
96 views25 pages

Morphological Operators Pv8

Morphological operations involve manipulating the shape and structure of objects in an image. They use small patterns called structuring elements to probe and modify images. Erosion removes pixels on object boundaries, shrinking objects. Dilation adds pixels to object boundaries, expanding objects. Opening performs erosion followed by dilation to smooth contours and close small holes. Closing performs dilation followed by erosion to smooth contours and fill small gaps. Together these operations can extract image components and remove imperfections.

Uploaded by

huachuhulk
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 25

Morphological operations

Morphological operations

 Morphology deals with structure

 Morphological image processing is used to extract image


components for representation and description of region
shape, such as boundaries, skeletons, and the convex hull

 Collection of non-linear operations related to the shape or


morphological feature of the image

 Used for removing imperfections


Reflection & translation
Reflection and translation

Courtesy: Gonzalez and woods, DIP


Structuring elements

 Probes an image with the small mask called “structuring


element” (SE)
 Structuring element is placed in all possible pixels of the
image and compared with the corresponding
neighbourhood of pixels.
 Operations are based on whether the structuring element
“fits” or “hits” (intersects) the neighbourhood.
Structuring elements
Hits and fits

Neither hits nor fits

HITS

FITS (completely contained or overlapped


Structuring element

 Is a small binary image


 Matrix dimension suggests the size of the structuring
element
 Pattern of ones zeros specifies the shape of structuring
element

0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 1 0 0 0 0 0 0 1 0 0 0
0 0 1 1 1 0 0 0 0 0 1 0 0 0
0 1 1 1 1 1 0 0 1 1 1 1 1 0
0 0 1 1 1 0 0 0 0 0 1 0 0 0
0 0 0 1 0 0 0 0 0 0 1 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0
Erosion

With A and B as sets in Z 2 , the erosion of A by B, denoted A - B,


defined
A - B  z | ( B ) Z  A

The set of all points z such that B, translated by z , is contained by A.


Erosion

 B is the structuring element


 Structuring element contained in set A – the elements A
and B completely overlap
 Erosion has a shrinking effect or is a thinning operation
 Origin of B visits every element in the set A
 For each location of the origin if B is completely contained
in A the location is a member of a new set otherwise not.
Courtesy: Gonzalez and woods, DIP
Erosion examples
Erosion Example
Original Image Processed Image With Eroded Pixels

Structuring Element
Erosion Example
Original Image Processed Image

Structuring Element
Dilation

2
With A and B as sets in Z , the dilation of A by B,
denoted A  B, is defined as

 
 A
A  B= z | B
z

Dilation example (Gonzalez)
Dilation Example
Original Image Processed Image

Structuring Element
Dilation Example
Original Image Processed Image With Dilated Pixels

Structuring Element
Dilation
 Growing or thickening effect on the objects of a binary image
 The extent of thickening is a function of shape of the
structuring element used
 superimpose the structuring element on top of the input image
so that the origin of the structuring element coincides with the
input pixel position.
 If at least one pixel in the structuring element coincides with a
foreground pixel in the image underneath, then the input pixel
is set to the foreground value.
 If all the corresponding pixels in the image are background,
however, the input pixel is left at the background value.
Opening and closing (compound
operations)

 Opening: generally smoothens the contour of an object and


breaks narrow isthmuses and eliminates thin protrusions

 Closing: also smoothens the sections of contours but as


opposed to opening it generally
 fuses narrow breaks and long thin gulfs and
 eliminates small holes and fills the gaps in the contour
Opening and closing

- +

+ -
Morphological processing - example

You might also like