0% found this document useful (0 votes)
19 views

Object Representation and Description

The document discusses various techniques for representing and describing objects and regions in digital images. It covers boundary-based and region-based representations, including boundary tracing algorithms, chain codes, boundary descriptors, shape signatures, and regional descriptors. Texture and structural descriptors are also discussed, along with moment invariants, Fourier descriptors, and principal component analysis.

Uploaded by

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

Object Representation and Description

The document discusses various techniques for representing and describing objects and regions in digital images. It covers boundary-based and region-based representations, including boundary tracing algorithms, chain codes, boundary descriptors, shape signatures, and regional descriptors. Texture and structural descriptors are also discussed, along with moment invariants, Fourier descriptors, and principal component analysis.

Uploaded by

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

EEE F435 (2023-24-I)

Digital Image Processing


(Object representation and description)
BITS Pilani Ashish Chittora
K K Birla Goa Campus
• Two ways to represent:
• External charactristics (e.g. Boundary)
• Internal charactristics (color, texture of the region)
Boundary following
• Moore’s Boundary Tracing algorithm (1968)
• Working with binary images
• Image is padded with border of 0’s to avoid the
possibility of an object merging with image border
• Limit our discussion to single region. (can be
extended to multiple disjoint regions also)
Boundary tracing
1) Start with left uppermost point with label 1.
2) Denote it as b0 and its west neighbor as c0 (background
pixel)
3) Examine 8-neighbors of b0, starting with c0 (clockwise).
Let b1 is the first neighbor encountered with value 1 and
let c1 be the background point immediately preceding
b1. Store b0 and b1 locations for use in step (7)
4) Let b=b1, c=c1
Boundary tracing
5) Let 8-neighbors of b starting from c (clockwise) be denoted by
n1, n2, … n8. Find first nk labeled as 1
6) b = nk , c = nk-1
7) Repeat steps (5) and (6) until b = b0 and next boundary point
found is b1.
8) Sequence of b-points found, constitutes the set of ordered
boundary points
4-directional 8-directional
Chain Code
Chain code : problems
• Problem 1: different starting points result in
different chain codes
* Solution: normalization -> redefine the starting
point such that the chain code forms an
integer of minimum magnitude
* E.g.: 6553320000 -> 0000655332
Chain code: problems
• Problem 2: object rotation results in different
chain codes
* Solution: difference code -> Treat the code as a
circular sequence and code with the
difference of directions (counter-clockwise)
• E.g.: 0000655332 -> 0006706076
Chain code : Rotation invariance

00664422
Chain code : Rotation invariance

00664422 77553311
Chain code : Rotation invariance

0 0 6 6 4 4 2 2 7 7 5 5 3 3 1 1

0 6 0 6 0 6 0 6 0 6 0 6 0 6 0 6
Differential chain code
Minimum perimeter polygonal (MPP)
approximation
• Polygonal approximation: approximate a
boundary using a polygon
- Min. perimeter polygons, min. no. of segments
• Choose an appropriate grid
- The boundary is enclosed by a set of
concatenated cells
• Allow the boundary to shrink as a rubber band
• Shrinking produces a shape of MPP
MPP approximation
MPP approximation
MPP Approximation
• Boundary consists of 4-connected
straight line segments
• Traverse the boundary in anti-
clockwise direction
• Every turn will be either concave
(Black) or convex (White) vertex
• Every concave (B) vertex in dark gray
(bounded) region has corresponding
“mirror vertex” in light gray
(boundary wall) region
• Vertices of MPP coincide either with
“convex vertices of inner wall” (W) or
the “mirror of concave vertices of
outer wall” (B)
MPP approximation
Polygonal approximation : splitting techniques
• Splitting techniques
→ Subdivide a boundary segment successively
into two parts until a specified criterion is
satisfied
1. Find two points on the boundary that are
farthest away and draw a line
→ Splitting line divides the boundary into two
boundary segments
2. For each boundary segment, find a point on the
boundary that has a maximum perpendicular
distance to its corresponding line
Polygonal approximation : splitting techniques
3. Draw two lines joining the point and the two end
points, respectively, of the corresponding splitting
line
→ Subdivide the boundary segment into two
parts
4. Repeat Steps 2-3 until the perpendicular distance
is less than a threshold
Minimum polygonal approximation
Minimum polygonal approximation
• Merging techniques
1. Merge points along a boundary until the least
square error line fit of the points merged so far
exceeds a threshold
2. Record the the two end point of the line
3. Repeat Steps 1 and 2 until all boundary points
are processed
Minimum polygonal approximation

Merging techniques
Signature

• Signature can be made invariant to translation, but sensitive to


rotation and scale
• Method of starting point selection can make the signature rotation
invariant
• Select point farthest from centroid
• Select point farthest from centroid along eigenaxis
• Use a chain code
Signature
Object description
• After selecting the ‘representation’, an object
or region in an image can be described by
suitable ‘descriptor’.
• Features selected as descriptor should be
insensitive to rotation, scaling and translation.
• For example:
• Representation: boundary
• Descriptor: length, orientation of line joining extreme
points of boundary etc.
Object description: Boundary descriptors
• Simple descriptors:
– Length of boundary
– Diameter of boundary
– Length and orientation of diameter (major axis)
– Minor axis = orthogonal to major axis
– Eccentricity = Major axis/Minor axis
– Curvature = rate of change of slope
• If boundary is traversed clockwise and change in slope at point
P is non-negative, the vertex point is part of “convex” segment.
Else “Concave” segment.
• “Straight” segment if change in slope ranges in 100 (say,
approx.)
• “Corner” point if change in slope exceeds 900 at a point.
Object description: Boundary descriptors
• Shape Number : First difference of smallest
magnitude chain code.
• Order of shape number (n) = no. of digits in
shape number
• n is even for a closed boundary
• n limits the no. of possible different shapes
• Shape no. is rotation invariant descriptor
Object description: Boundary descriptors
Object description: Boundary descriptors
• Fourier descriptors: Let the K-boundary points
are (x0,y0), (x1,y1),……(xK-1,yK-1)

𝐾−1
1 2𝜋𝑘
𝑗 𝐾 𝑢
𝑠(𝑘) = ෍ 𝑎(𝑢)𝑒
𝐾 , k = 0,1,2,…, K-1
𝑛=0
Object description: Boundary descriptors
• Fourier descriptors:
Object description: Boundary descriptors
• Fourier descriptors:
Example: Fourier descriptor
• Find Fourier-descriptors for the following
boundary coordinates starting from point O. and
Verify the FD’s translation property for translation
∆xy = 2+3j.
Object description: Boundary descriptors
• Statistical moments
Object description: Boundary descriptors
• Statistical moments
Object description: Regional descriptors
Simple Regional descriptors
Simple Regional descriptors

• For perfectly circular region C(S) =1


Simple Regional descriptors
Simple Regional descriptors
Simple Regional descriptors
Topological descriptors
Topological descriptors
Topological descriptors

V= N. of vertices
Q=No. of edges
F=No. of faces
Texture descriptors
Histogram approaches
Histogram approaches
Histogram approaches
Structural approaches
Structural approaches
Spectral approaches
Spectral approaches
Spectral approaches
Spectral approaches
Spectral approaches
Moment invariants
Moment invariants
Moment invariants
Moment invariants
Moment invariants
Moment invariants
Principle component analysis
PCA
PCA
PCA
PCA
• Instead of mean and variance of random
variable we will use mean vector and
Coavariance matrix of random vectors
mx = E{x} and CX = E{(x-mx)(x-mx)T}
where, Cx is a nxn matrix (real and symmetric) and
its elements
Cii = variance of xi
Cij=covariance of xi and xj
For uncorrelated xi and xj => Cij = Cji = 0
PCA
• Given N data points x1, x2,…xN, in Rn
• We want to find a new set of features that are
linear combinations of the original ones

Cx =
PCA
PCA
• Because CX is real, symmetric and positive definite
its eigenvalues (λi) are non negative and its
eigenvectors (vi) are orthogonal.
Cx vi = λi vi
• Let 𝜆1 ≥ 𝜆2 ≥ 𝜆3 … . ≥ 𝜆𝑛 be the eigenvalues of CX in
descending order and A be a matrix whose rows
are the eigenvectors of CX
PCA
• Suppose we use the transformation matrix A
such that
y = A(x-mX)
(This is called Hotelling transform)
Here my = E{y} = 0
(mean of y-vectors is zero)
• Covariance of y-vectors is given as
Cy = ACXAT
PCA
• Cy is a diagonal matrix whose elements along
main diagonal are eigenvalues of CX

• CX and Cy have same eigenvalues


PCA
• Rows of A are orthonormal vectors (A-1 = AT) and
x can be recovered or reconstructed from y by
x = ATy+mx
• Suppose instead of using all eigenvectors of Cx,
we form AK (k x n matrix) from k-eigenvectors
(of k-largest eigenvalues)

• The mean square reconstruction error


PCA : Example
PCA : Example
PCA : Example
PCA : Face recognition
PCA : Face recognition
Thankyou

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy