Image Representation
Image Representation
Image Representation
and Description
Dr. A S Jalal
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Image Representation and Description?
Objective:
To represent and describe information embedded in
an image in other forms that are more suitable than the
image itself.
Benefits:
- Easier to understand
- Require fewer memory, faster to be processed
- More “ready to be used”
What kind of information we can use?
- Boundary, shape
- Region
- Texture
- Relation between regions
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Representation & Description
Segmentation techniques yield raw data in the
form of pixels along a boundary or pixels
contained in a region.
After segmentation, the image needs to be
described and interpreted.
Representation: an object may be represented by its
boundary.
Description: the object boundary may be described by
its length, orientation, or number of concavities...
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Representation
An object can be represented by:
Its
external characteristics, such as its
boundary.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
These objects are recognized by...…
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
These objects are recognized by…
Texture Color Context Shape
X X
X X
X X
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Description
The features that represent the image are used
as descriptors.
representation boundary
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Description …
Descriptors should not be sensitive to variations
like :
– Size Change
– Translation
– Rotation
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
What are invariants?
Invariants are functionals defined on the
image space such that
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Discrimination power
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Boundary (Border) Following
Step 4: Mark the current pixel as previous pixel & the next pixel as
the current pixel.
Step 5: Go to step 3
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Boundary (Border) Following …
1 1 1 1
1 1
1 1
1 1
1 1 1 1
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Chain Codes
Represent a boundary of a connected region
Why focus on a boundary?
The boundary is a good representation of an object shape
and also requires less memory.
Chain codes: represent an object boundary by a connected
sequence of straight line segments of specified length and
direction.
The direction of each segment is coded by using a
numbering scheme shown below
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Chain Codes …
1101101030332330322212
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Chain Codes …
22120207656764443
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Chain Codes …
Unacceptable because
the resulting chain of codes tends to be quite long
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Problems with the Chain Code
Chain code representation is conceptually
appealing, yet has the following two problems
Dependent on the starting point
Dependent on the orientation
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Normalization Strategy
to overcome the starting point problem
33001122
33001122 00112233
30011223 01122330
00112233 11223300 First row gives the
01122330 Sort 12233001 normalized chain code
11223300 rows 22330011 00112233
12233001 23300112
22330011 33001122
23300112 30011223
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
The First Difference of a Chain Codes
Problem of a chain code:
a chain code sequence depends on a starting point.
Solution: treat a chain code as a circular sequence and redefine the
starting point so that the resulting sequence of numbers forms an
integer of minimum magnitude.
33001212 33010122
01011311
01011311 01131101
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Shape Numbers
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Shape Numbers …
Find the shape number & order of the given boundary.
Order :8
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Shape Number …
1
Shape number of the boundary definition:
the first difference of smallest magnitude
2 0
The order n of the shape number:
the number of digits in the sequence
3
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Shape Number …
Shape numbers of order
4, 6 and 8
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Shape Number …
1. Original boundary
Chain code:
000030032232221211
First difference:
300031033013003130
4. Find the nearest
Shape No.
3. Create grid Grid.
000310330130031303
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Polygon Approximation
Represent an object boundary by a polygon
Minimum perimeter
Object boundary
polygon
Minimum perimeter polygon consists of line segments that
minimize distances between boundary pixels.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Polygon Approximation:Splitting Techniques
1. Find the line joining
two extreme points
0. Object boundary
2. Find the
farthest points
from the line
3. Draw a polygon
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Distance-Versus-Angle Signatures
Represent an 2-D object boundary in term of a 1-D function
of radial distance with respect to q.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Fourier Descriptor
Fourier descriptor: view a coordinate (x,y) as a complex number
(x = real part and y = imaginary part) then apply the Fourier
transform to a sequence of boundary points.
Let s(k) be a coordinate
of a boundary point k : s(k ) x(k ) jy(k )
1 K 1
Fourier descriptor : a (u) s(k )e 2uk / K
K k 0
Reconstruction formula
1 K 1
s(k ) a (u )e2uk / K
K k 0
Boundary
points
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Example: Fourier Descriptor
Examples of reconstruction from Fourier descriptors
1 P 1
sˆ(k ) a (u )e2uk / K
K k 0
P is the number of
Fourier coefficients
used to reconstruct
the boundary
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Eccentricity
Ratio of the major to the minor axis
Major axis = the line connecting the two extreme
points that comprise the diameter
Minor axis = the line perpendicular to the major
axis
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Statistical Moments
Definition: the nth moment
K 1
n ( r ) ( ri m)n g ( ri )
i 0
Example of moment:
where K 1 The first moment = mean
m ri g ( ri ) The second moment = variance
i 0
Boundary
segment
1D graph
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Regional Descriptors …
- area of the region: the number of pixels in the region
- perimeter = length of its boundary
- Compactness
A( R)
C 2
P ( R)
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Topological Descriptors
Use to describe holes and connected components of the region
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Example: Euler number
E = -1
E=0
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Texture Descriptors
Purpose: to describe “texture” of the region.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Texture Descriptors …
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Texture Descriptors …
repetition
stochastic
both
fractal
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Co-occurrence Matrix
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Co-occurrence Matrices
The intensity histogram is very limited in describing a texture
(f.e - checkerboard versus white-black regions.
Use higher-level statistics: Pairs distribution.
0 1 2 3
Example:
0 0 1 1 0 2 2 1 0
•co-occurrence matrix of 0
I(x,y) and I(x+1,y) 0 1 1
1 0 2 0 0
•Normalize the matrix to 0 2 2 2 2 0 0 3 2
get probabilities.
2 2 3 3 3 0 0 0 1
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Co-occurrence Matrix …
What do these measure?
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Statistical Approaches for Texture Descriptors
We can use statistical moments computed from an image histogram:
K 1 z = intensity
n ( z ) ( zi m) p( zi ) n
p(z) = PDF or histogram of z
i 0
where K 1
m zi p( zi )
1
R( z ) 1
i 0
1 2 ( z)
A
B
C
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Projection matching
• Projection matching
• Horizontal & vertical projection: Each row and each
column become a bin in the histogram. The count that is
stored in a bin is the number of 1-pixels that appear in
that row or column.
• Diagonal projection: An alternative is to define the
bins from the top left to the bottom right of the shape.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Horizontal and vertical projections
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Elongatedness
The ratio of the height and width of a rotated
minimal bounding box. In other words, rotate a
rectangle
so that it is the smallest rectangle in which the shape
fits. Then compare its height to its width.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Rectangularity
How rectangular a shape is (how much it fills its
minimal bounding box): area of object/area of
bounding box.
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Moments of Two-D Functions
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Moments of
The moment of order p + q
Two-D Functions …
m01
m pq x p y q f ( x, y ) x
m10 y
x y m00 m00
The central moments of order p + q
pq ( x x ) p ( y y ) q f ( x, y )
x y
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Moments of Two-D Functions …
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal
Example: Invariant Moments of Two-D Functions
Class Presentations on Image Processing And Analysis by Dr. Anand Singh Jalal