Image Segmentation and
Extraction of object from an
image
CH.Venkanna
EC104018
M.Tech (E.I)
1
Introduction to image segmentation
The purpose of image segmentation is to partition an
image into meaningful regions with respect to a
particular application
The segmentation is based on measurements taken
from the image and might be greylevel, colour, texture,
depth or motion
2
Introduction to image segmentation
Usually image segmentation is an initial and vital
step in a series of processes aimed at overall image
understanding
Applications of image segmentation include
Identifying objects in a scene for object-based
measurements such as size and shape
Identifying objects in a moving scene for object-based
video compression (MPEG4)
4
Introduction to image segmentation
Example 1
Segmentation based on greyscale
Very simple ‘model’ of greyscale leads to inaccuracies in
object labelling
5
Different Methods of image
segmentation
There are different types of segmentation methods are
proposed. These are
Thresholding
Clustering
Relaxation labelling
EM algorithm(Proposed Algorithm)
The Expectation/Maximization (EM)
algorithm
In general we may imagine that an image comprises L
segments (labels)
Within segment l the pixels (feature vectors) have a
probability distribution represented by pl ( x | l )
represents the parameters of the data in segment l
l
Mean and variance of the greylevels
Mean vector and covariance matrix of the colours
Texture parameters
7
The Expectation/Maximization (EM)
algorithm
The incomplete data are just the measured pixel greylevels or
feature vectors
We can define a probability distribution of the incomplete data
as pi ( x;1 , 2 ..... L )
The complete data are the measured greylevels or feature
vectors plus a mapping function f (.) which indicates the
labelling of each pixel
Given the complete data (pixels plus labels) we can easily work
out estimates of the parameters
l : l 1..L
But from the incomplete data no closed form solution exists
The Expectation/Maximization (EM)
algorithm
The algorithm is as follows:
Initialize an estimate of l : l 1..L
Repeat
Step 1: (E step)
Obtain an estimate of the labels based on the
current parameter estimates
Step 2: (M step)
Update the parameter estimates based on the current
labelling
Until Convergence
9
The Expectation/Maximization (EM)
algorithm
A recent approach to applying EM to image
segmentation is to assume the image pixels or feature
vectors follow a mixture model
Generally we assume that each component of the
mixture model is a Gaussian
A Gaussian mixture model (GMM)
p( x | ) l 1 l pl ( x | l )
L
1 1
pl ( x | l ) exp( ( x l ) l ( x l ))
T 1
(2 ) det( l )
d /2 1/ 2
2
L
l 1
l 1
10
The Expectation/Maximization (EM)
algorithm
Our parameter space for our distribution now includes
the mean vectors and covariance matrices for each
component in the mixture plus the mixing weights
1 , 1 , 1 ,.......... L , L , L
We choose a Gaussian for each component because
the ML estimate of each parameter in the E-step
becomes linear
11
The Expectation/Maximization (EM)
algorithm
Define a posterior probability P (l | x j , l ) as the
probability that pixel j belongs to region l given the
value of the feature vector x j
Using Bayes rule we can write the following equation
l pl ( x j | l )
P(l | x j , l )
L
k 1
k pk ( x | k )
This actually is the E-step of our EM algorithm as
allows us to assign probabilities to each label at each
pixel
12
The Expectation/Maximization (EM)
algorithm
The M step simply updates the parameter estimates
using MLL estimation
1 n
l
( m 1)
P(l | x j , l( m ) )
n j 1
n
j
x P
j 1
(l | x j , l
(m)
)
l( m 1) n
P(l | x ,
j 1
j l
(m)
)
n
P
j 1
(l | x j , l
(m)
) ( x j l
( m)
)( x j l
( m) T
)
l( m 1) n
P (l
j 1
| x j , l
(m)
)
13
Fig : Original image
Fig : (Right column) The proposed image segmentation, (left column)
direct segmentation
Extraction of object from an image
After partition an image into meaningful regions
and sometimes it is required extract object from an
image
Extraction founds many applications in Biometric
image processing and face recognition.
Face Feature Extraction(voronoi Diagram method)
Detecting eyes
Detecting nose and mouth
Fig : Extraction of eyes ,nose and mouth from an image
Extraction of alphabet from
number plate
Fig : Original image and segment image,extracting
alphabet .
Conclusion
The EM algorithm is general image segmentation
technique in computer vision with many
applications.
Extraction found many applications in security system
and biometric image processing.
19