Professional Documents
Culture Documents
Reference
R. Jain, R. Kasturi, and B. Schunk.
Machine Vision,
McGraw Hill, 1995, ISBN 0-07-032018-7
Introduction to AR
8. Basic Computer Vision
Overview
Image Formation (Geometry, Radiometry)
Feature Detection
Region(Similarity)-based Approaches
Edge(Difference)-based Approaches
Introduction to AR
8. Basic Computer Vision
1. Image Formation
Image geometry
(Image radiometry)
Introduction to AR
8. Basic Computer Vision
Image Geometry
- Pinhole Projection -
Object point
(x,y,z)
Image plane
(inverted)
r
x
r
(x,y)
Introduction to AR
8. Basic Computer Vision
Image Geometry
- Pinhole Projection -
Image plane
Object point
(x,y,z)
x
(x,y)
y
r
Introduction to AR
8. Basic Computer Vision
Image Geometry
Image plane
y
Image array
0
column j
m-1
0
.
.
pixel a[i,j]
row i
(x,y)
x
.
.
n-1
x = j - m2- 1
y = - (i - n2- 1)
Introduction to AR
8. Basic Computer Vision
Image Radiometry
- Basic -
Sa
tu
rat
ion
Hue
Overview
Image Formation (Geometry, Radiometry)
Feature Detection
Region(Similarity)-based Approaches
Edge(Difference)-based Approaches
Introduction to AR
8. Basic Computer Vision
Thresholding, Histograms
Connected Components
Region Boundaries
Region Properties
Morphological Operations
Introduction to AR
8. Basic Computer Vision
10
2. Image Thresholding
Thresholding
Lookup tables
0, if fA[i,j] < t
1, if fA[i,j] > t
fB[i,j] =
fB[i,j] = lookup [fA[i,j]]
I(x)
t1
t2
x
Introduction to AR
8. Basic Computer Vision
11
h(I)
P-tile method
Mode method
Iterative threshold selection
Adaptive, variable thresholding
Double thresholding
000110010
000110110
111111110
011111000
000110110
Introduction to AR
8. Basic Computer Vision
12
010
111
010
000110010
000110110
111111110
011111000
000110110
111
111
111
4-path, 8-path
Connected components 8
Background and holes 4
Boundary
Introduction to AR
8. Basic Computer Vision
-Pixel Neighborhoods-
010
101
010
4
8
010
101
010
13
- Algorithms -
000110010
000110110
111111110
011111000
000110220
label it
recurse
Introduction to AR
8. Basic Computer Vision
14
000110010
000110110
111111110
011111000
000110220
Introduction to AR
8. Basic Computer Vision
15
234
1x5
876
Introduction to AR
8. Basic Computer Vision
16
Region Properties
- Geometric (Moments) -
Introduction to AR
8. Basic Computer Vision
000110010
000110110
111111110
011110000
000110110
17
Region Properties
- Photometric -
Introduction to AR
8. Basic Computer Vision
18
Introduction to AR
8. Basic Computer Vision
19
Overview
Image Formation (Geometry, Radiometry)
Feature Detection
Region(Similarity)-based Approaches
Edge(Difference)-based Approaches
Introduction to AR
8. Basic Computer Vision
20
3. Edge Detection
Maximal/Minimal
Image Gradient
I(x)
(Optima in the
1rst derivative)
I(x)
Introduction to AR
8. Basic Computer Vision
21
Edge Detection
- Continuous Case -
f
x
f
y
Introduction to AR
8. Basic Computer Vision
22
1 0
0 -1
0 -1
1 0
Sobel
-1 0 1
-2 0 2
-1 0 1
1 2 1
0 0 0
-1 -2 -1
-1 0 1
-1 0 1
-1 0 1
1 1 1
0 0 0
-1 -1 -1
Prewitt
Introduction to AR
8. Basic Computer Vision
23
2f
x2
2f
y2
2f
x2
2f
y2
1 4 1
4 -20 4
1 4 1
Introduction to AR
8. Basic Computer Vision
24
f(x + x, y + y) g(x, y) dx dy
- n-1 m-1
h [i,j] =
Introduction to AR
8. Basic Computer Vision
25
h [i,j] =
i
convolution mask
g(k,l)
Introduction to AR
8. Basic Computer Vision
26
Introduction to AR
8. Basic Computer Vision
27
Edgels
I(x)
I(x)
Introduction to AR
8. Basic Computer Vision
28
Introduction to AR
8. Basic Computer Vision
29
1 1 1
1 1 1 * 1/9
1 1 1
1 2 1
2 4 2 * 1/16
1 2 1
- (k2+l2)
2
g[k,l] = e 2
1
1
2
2
2
1
1
Introduction to AR
8. Basic Computer Vision
1
2
2
4
2
2
1
2 2 2
2 4 2
4 8 4
8 16 8
4 8 4
2 4 2
2 2 2
1
2
2
4
2
2
1
1
1
2
2
2
1
1
with
k: -n/2 .. n/2
l: -m/2 .. m/2
* 1 / 144
30
3.4.2 Enhancement
Gradient-based edge detection
Second derivative
Introduction to AR
8. Basic Computer Vision
31
3.4.3 Detection
Introduction to AR
8. Basic Computer Vision
32
Introduction to AR
8. Basic Computer Vision
33
0
-1
-2
-1
0
-1 0 0
-2 -1 0
16 -2 -1
-2 -1 0
-1 0 0
Introduction to AR
8. Basic Computer Vision
0
0
0
0
0
0
-1
-1
-1
-1
-1
0
0
0
0
0
0
0
0
0
0
-1
-1
-1
-1
-1
-1
-1
-1
-1
0
0
0
0
0
0
-1
-1
-1
-2
-3
-3
-3
-3
-3
-2
-1
-1
-1
0
0
0
0
-1
-1
-2
-3
-3
-3
-3
-3
-3
-3
-2
-1
-1
0
0
0
-1
-1
-2
-3
-3
-3
-2
-3
-2
-3
-3
-3
-2
-1
-1
0
0
-1
-2
-3
-3
-3
0
2
4
2
0
-3
-3
-3
-2
-1
0
-1
-1
-3
-3
-3
0
4
10
12
10
4
0
-3
-3
-3
-1
-1
-1
-1
-3
-3
-2
2
10
18
21
18
10
2
-2
-3
-3
-1
-1
-1
-1
-3
-3
-3
4
12
21
24
21
12
4
-3
-3
-3
-1
-1
-1
-1
-3
-3
-2
2
10
18
21
18
10
2
-2
-3
-3
-1
-1
-1
-1
-3
-3
-3
0
4
10
12
10
4
0
-3
-3
-3
-1
-1
0
-1
-2
-3
-3
-3
0
2
4
2
0
-3
-3
-3
-2
-1
0
0
-1
-1
-2
-3
-3
-3
-2
-3
-2
-3
-3
-3
-2
-1
-1
0
0
0
-1
-1
-2
-3
-3
-3
-3
-3
-3
-3
-2
-1
-1
0
0
0
0
-1
-1
-1
-2
-3
-3
-3
-3
-3
-2
-1
-1
-1
0
0
34
0
0
0
0
-1
-1
-1
-1
-1
-1
-1
-1
-1
0
0
0
0
0
0
0
0
0
0
-1
-1
-1
-1
-1
0
0
0
0
0
0
-1 1
-1 1
1 1
-1 -1
Introduction to AR
8. Basic Computer Vision
35
Introduction to AR
8. Basic Computer Vision
36
Shape Fitting
- Quality Criteria -
Goodness of fit
Introduction to AR
8. Basic Computer Vision
37
Shape Fitting
- Models -
Introduction to AR
8. Basic Computer Vision
38
Polylines
Sequence of line segments
implicit line representation f(x,y) = 0
distance from line -> f(x,y) = d
Introduction to AR
8. Basic Computer Vision
39
Overview
Image Formation (Geometry, Radiometry)
Feature Detection
Region(Similarity)-based Approaches
Edge(Difference)-based Approaches
Introduction to AR
8. Basic Computer Vision
40
Geometric (Shapes)
One object at a time (unique recognition): Geometric invariants
under 3D transformations and projections
Groups of objects in combination (graph matching)
Introduction to AR
8. Basic Computer Vision
41
Continue loop
Introduction to AR
8. Basic Computer Vision
42
Example:
Introduction to AR
8. Basic Computer Vision
43
2D Motion Estimation
Compute local motion
vectors of every
feature (images n-1,
n-2)
(more images to
estimate higherorder motion models)
Introduction to AR
8. Basic Computer Vision
44
2D Motion Prediction
Prediction of local
feature motion for
image n
Introduction to AR
8. Basic Computer Vision
45
Target Redetection
Prediction of local
feature motion for
image n
Introduction to AR
8. Basic Computer Vision
46
- Cross Correlation -
unnormalized:
r(i,j) = {t(x,y) * s(i+x,j+y)}
x,y
normalized:
r(i,j) =
{[t(x,y)-T]*[s(i+x,j+y)-Sij]}
[t(x,y) - T]2 * [s(i+x,j+y) - Sij]2
Image 1
Image 2
j
i
template t,
mean T
Introduction to AR
8. Basic Computer Vision
search region s
mean Sij (i,j)
47
I(x,t)
v = dy = ...
I(x1,t)
t+1
I(x1,t+1)
x1
x2
dx
Introduction to AR
8. Basic Computer Vision
48
I[x,y,t]
flow[u,v]=
flow[dx/dt,dy/dt]
Introduction to AR
8. Basic Computer Vision
49
P
D
v = vaverage - Iy
P
D
P = Ix uaverage + Iy vaverage + It
D = 2 + Ix2 + Iy2
Introduction to AR
8. Basic Computer Vision
50
u + u + v v
+
x y x v
sm(x,y,t) =
dx dy
Minimize:
2
(flow(x,y,t) + smoothness(x,y,t)) dx dy
Introduction to AR
8. Basic Computer Vision
51
Introduction to AR
8. Basic Computer Vision
52