morphological image processing (chapter 9)
DESCRIPTION
Morphological Image Processing (Chapter 9). CSC 446 Lecturer: Nada ALZaben. Outline: . Introduction. Some basic Concepts from Set theory Logic operations involving Binary Images. Dilation and Erosion Open and Close The Hit-and-Miss transformation Thinning and T hicking - PowerPoint PPT PresentationTRANSCRIPT
Morphological Image Processing(Chapter 9)
CSC 446 Lecturer: Nada ALZaben
Outline : Introduction. Some basic Concepts from Set theory Logic operations involving Binary
Images. Dilation and Erosion Open and Close The Hit-and-Miss transformation Thinning and Thicking Processing gray scale images.
IntroductionThe word morphology commonly
denotes a branch of biology that deals with the form and structure of animals and plants.
Mathematical morphology is a tool that extract image components that are useful in the representation and discription of region shape such as:BoundariesSkeletonsConvex hull .
Sets in mathematical morphology represent objects in an image.
Some basic Concepts from Set theory
Let A be set in . If a= is an element of A then we write:
if not we say Empty set is called null set and denoted by Sets are specified by the contents of two braces
{}.Elements of the sets in this chapter are the pixel
coordinates of representing objects in an image. Example:- when we write we mean that set C is the set of elements w such that w is formed by multiplying each of the two coordinates of all the elements of set D by -1.
Some basic Concepts from Set theory.. (cont.) if every elements A is also an element of
another set B then A is subset of B, .Union of sets take all elements of A and B is .Intersection of two sets A and B is set of
elements belonging to both A and B , .Two sets are disjoint or mutually exclusive if
they have no common elements The complement of a set A is the set of
element not contained in A. } The difference of two sets A and B is , w
B}=
Some basic Concepts from Set theory.. (cont.) The reflection of set B is is defined
as
The translation of set A by point z=( ), is defined as
Example.
Logic Operation Involving Binary Images .Mostly used images are the binary
images.The principle logic operations used in
image processing are AND, OR and NOT
Logic operations are operated on a pixel by pixel basis between 2 images ,but, (NOT) operation use one image.
Logic Operation Involving Binary Images .More operations:XOR: when only 1 in a pixel or the
other pixel is 1 but not both.NOT-AND: select the black pixel that
simultaneously are in B but not in A.NOTE:
Intersection ==ANDUnion ==ORComplement ==NOT
Logic Operation Involving Binary Images .
Logic Operation Involving Binary Images .
Note: -In binary images white will represent the foreground (1) while black is the background (0). -The set of coordinate to the image is simply the set of 2D Euclidean coordinates of al the foreground pixels in the image as the origin normally takes in one of the corners.
Dilation and Erosion Dilation is a morphological transformation
which essentially expands an object by adding a layer of pixels around it’s edges and as a result it shrinks any hole in the object.
With A and B as sets in the Dilation of A by B denoted as:
This equation means get the reflection of B about its origin and shifting this reflection by z. the dilation of A by B then is a set of all displacements z such that and A overlap by at least one element.
B usually called structuring element (kernal).
Dilation and Erosion
Dilation advantage in bridges gaps in an image.
Dilation and Erosion 1 1 11 1 11 1 1
Dilation and Erosion Erosion is a morphological dual to
dilation which essentially shrinks an object by removing a layer of pixels around it’s edges and as a result it expands any hole in the object.
With A and B as sets in the Erosion of A by B denoted as:
Meaning the erosion of A by B then is a set of all points z such that translated by z is contained in A.
Dilation and Erosion
Erosion advantage in eliminating irrelevant details in term of size in an image.
Note: if the structure element is larger than the object then the object will be eliminated completely
Opening and Closing Now we know that Erosion shrinks an
object while Dilation expands it.By combining these operations we get
Open or Close operation.Open: Erosion then Dilation Close: Dilation then Erosion.
Opening and closing smothes the contour of an object but:Opening: breaks narrow lines and
eliminates thin protrusions( do thickening) Closing: focus on thin protrusions so it
eliminates small holes and fill gaps.
Opening and Closing Opening:Closing: ex:
Processing gray scale imagesSame methods can be applied to gray
scale images just little modification. Grayscale erode: output at a point is
minimum of image pixel and structuring element pixel.
Grayscale dilate: output is maximum of image and structuring element.
Processing gray scale images
0 0 0 0 0 0 0 00 0 3 5 5 3 0 00 0 5 9 9 5 0 00 0 3 5 5 3 0 00 0 0 0 0 0 0 0
1 11 1
1 1 1 1 1 1 1 11 1 4 6 6 6 4 11 1 6 1
010
10
6 1
1 1 6 10
10
10
6 1
1 1 4 6 6 6 4 1
-1
-1
-1
-1
-1
-1
-1
-1
-1 -1 2 4 2 -1 -1 -1-1 -1 2 4 2 -1 -1 -1-1 -1 -1 -1 -1 -1 -1 -1-1 -1 -1 -1 -1 -1 -1 -1
Initial image
Dilation results Erosion results
The structuring element
The Hit-and-Miss transformThe hit-and-miss transform is a general
binary morphological operation that can be used to look for particular patterns of foreground and background pixels in an image. A⊛B
It is actually the basic operation of binary morphology since almost all the other binary morphology operators can be derived from it.
As with other binary morphology operators it takes as input a binary image and a structuring element and produce another binary image as output.
The Hit-and-Miss transformThe structure element contain both
1 and 0The operation is done as:
translating the structure image over all points in the image then by comparing the structure element 1’s and 0’s with image if they match then set the underlying pixel to foreground otherwise set as background.
Ex….
X 1 X0 1 10 0 X