Blob Analysis

advertisement
OBJECT RECOGNITION – BLOB ANALYSIS
•Examples of form parameters that are invariant with
respect to position, orientation, and scale:
•Number of holes in the object
•Compactness or Complexity: (Perimeter)2/Area
•Moment invariants
•All of these parameters can be evaluated during
contour following.
GENERALIZED MOMENTS
•Shape features or form parameters provide a high level
description of objects or regions in an image
•Many shape features can be conveniently represented
in terms of moments. The (p,q)th moment of a region R
defined by the function f(x,y) is given by:
m pq   x y f ( x, y)dxdy
p
R
q
GENERALIZED MOMENTS
•In the case of a digital image of size n by m pixels, this
equation simplifies to:
n
m
M ij   x y f ( x, y)
i
j
x 1 y 1
•For binary images the function f(x,y) takes a value of 1
for pixels belonging to class “object” and “0” for class
“background”.
GENERALIZED MOMENTS
n
m
M ij   x i y j f ( x, y)
x 1 y 1
X
i
j
Mij
1
0
0
2
1
0
7
33
3
0
1
20
4
2
0
5
0
2
159
64
1
1
93
0 1 2 3 4 5 6 7 8 9
6
Y
Area
Moment
of Inertia
SOME USEFUL MOMENTS
•The center of mass of a region can be defined in
terms of generalized moments as follows:
M 10
X 
M 00
M 01
Y
M 00
SOME USEFUL MOMENTS
•The principal axis of an object is the axis passing
through the center of mass which yields the minimum
moment of inertia.
•This axis forms an angle θ with respect to the X axis.
•The principal axis is useful in robotics for determining
the orientation of randomly placed objects.
2M 11
TAN 2 
M 20  M 02
Principal Axis: Derivation
Example
X
Principal Axis
Center of Mass
Y
SOME USEFUL MOMENTS
•The moments of inertia relative to the center of mass
can be determined by applying the general form of
the parallel axis theorem:
M 02
2
01
M
 M 02 
M 00
M 20
2
10
M
 M 20 
M 00
M 10 M 01
M 11  M 11 
M 00
SOME (MORE) USEFUL MOMENTS
•The minimum/maximum moment of inertia about an
axis passing through the center of mass are given by:
I MIN
( M 02  M 20 )  4M
M 02  M 20


2
2
2
11
I MAX
( M 02  M 20 )  4M
M 02  M 20


2
2
2
11
2
2
SOME (MORE) USEFUL MOMENTS
•The following moments are independent of position,
orientation, and reflection. They can be used to
identify the object in the image.
1  M 20  M 02
2  ( M 20  M 02 )  4M
2
2
11
SOME (MORE) USEFUL MOMENTS
•The following moments are normalized with respect
to area. They are independent of position, orientation,
reflection, and scale.
1 
1
M
2
00
2 
2
M
4
00
Download