Professional Documents
Culture Documents
Affine Transformations
Affine Transformations
Similarity preserves:
Angles
Length ratios
Will show:
Projective distortion can be removed once image of line at
infinity is specified
Affine distortion removed once image of circular points is specified
Then the remaining distortion is only similarity
A
0
A
t
1
l H AT l
0
0 l
1
rectification
Euclidean plane
Two step process:
1.Find l the image of line
at infinity in plane 2
2. Transform l to its
canonical position
(0,0,1) T by plugging into
HPA and applying it to
the entire image to get a
rectified image
3. Make affine measurements
on the rectified image
H PA
1 0 0
0 1 0 H A
l1 l2 l3
l l1 l2
l3 , l3 0
T
v1
l1
l3
l2
v2
v 2 l3 l 4
v1 l1 l 2
l4
l v1 v 2
c
Circle:
Line at infinity
x3 0
x12 + x22 = 0
I 1, i,0
J 1,-i,0
1
I i
0
s cos
I H S I s sin
J i
0
s sin
s cos
0
Canonical coordinates
of circular points
tx 1
1
i
t y i se i I
0
1 0
1 0 0
*
C 0 1 0
0 0 0
C* H S C* H TS
The dual conic C*is fixed conic under the
projective transformation H iff H is a similarity
Note:C*
has 4DOF (3x3 homogeneous; symmetric, determinant is zero)
l is the nullvector
Angles
l l1 , l2 , l3
2
1
Projective: cos
m m1 , m2 , m3
l1m1 l2 m2
projective transformation
l T C* m
T
C* l m T C* m
l T C* m 0 (orthogonal)
Length ratios
d (b, c) sin
d (a, c) sin
H P H A H S C* H TS H P H A
H P H A C H P H A
*
KK T
T
v K
K T v
T
v v
Upshot: projective (v) and affine (K) components directly determined from the image
of C*
Once C* is identified on the projective plane then projective distortion may be
rectified up to a similarity
*
C
Can show that the rectifying transformation is obtained by applying SVD to
'
1 0 0
C* ' U 0 1 0 U T
0 0 0
HU
Apply U to the pixels in the projective plane to rectify the image up to a Similarity
Rectifying
Transformation: U
C*
C* '
Euclidean
Projectively
Distorted
Image
Similarity transformation
Rectified image
Recovering up to a similarity
from Affine
affine
transformation
C*
Euclidean
Rectifying
Transformation: U
C* '
Affinely
Distorted
Image
Similarity transformation
Rectified image
l2
l3
KK
m1
0
m2 0
0
m
3
2
11
Affine
k , k11k12 , k
2
12
rectified
2 T
22
l2
l3
KK
T
v
K
m1
K v
m2 0
T
v v
m
3
T
Projective 3D geometry
Singular Value
Decomposition
A mn U mm mn VnTn
1 0
0
2
mn
1 2 n 0
0
0
0 0
UT U I
VTV I
Singular Value
Decomposition
U
V
Homogeneous least-squares
min AX subject to X 1
solution X Vn
1 0
0
2
0
0
0 0
0 0
0 0
0 0
~
diag 1 , 2 , , r , 0r 1,,
,, 0n
Pseudo inverse
A V U T diag 11 , 21 ,, r1 , 0 ,, 0
Projective 3D Geometry
Points, lines, planes and
quadrics
Transformations
, and
3D points
3D point
X , Y , Z T in R3
X X 1 , X 2 , X 3 , X 4 in P3
T
X1 X 2 X 3
X
,
,
,1
X4 X4 X4
X , Y , Z , 1
projective transformation
X 4 0
Planes
3D plane
Transformation
X' H X
' H -T
1 X 2Y 3 Z 4 0
1 X 1 2 X 2 3 X 3 4 X 4 0
TX 0
Euclidean representation
~
T
n . X d 0 n 1 , 2 , 3
4 d
~
T
X X ,Y , Z
X4 1
d/ n
X1T
T
X2 0
X 3T
(solve
as right nullspace of
X1T
T
X2
X 3T
X
X
X
X
1 4
2 4
3 4
4
1T
T
2 X 0
3T
(solve
1T
X as right nullspace of T2
3T
X Mx
M X1X 2 X 3
T M 0
M is 4x3 matrix. Columns of M are null space of T
X is a point on plane
x ( a point on projective plane P2 ) parameterizes
points on the plane
M is not unique
Lines
A
W T
2x4 B
Example: X-axis:
P
W T
2x4
Q
T
W * W T = WW * = 0 22
0 0 0 1
W
1
0
0
0
0 0 1 0
W
0
1
0
0
W
M T
X
M 0
W*
M T
W*
MX 0
1.
2.
3.
4.
5.
9 d.o.f.
in general 9 points define quadric
det Q=0 degenerate quadric
(plane quadric)=conic
C M T QM
transformation Q' H -T QH -1
: X Mx
T Q* 0
1.
2.
-1
Quadric classification
Rank
Sign
.
4
2
Diagonal
Equation
(1,1,1,1)
(1,1,1,-1)
(1,1,-1,-1)
Hyperboloid (1S)
3
1
(1,1,1,0)
(1,1,-1,0)
Single point
Cone
2
0
(1,1,0,0)
(1,-1,0,0)
X2+ Y2= 0
X2= Y2
Single line
Two planes
(1,0,0,0)
X2=0
Single plane
Realization
No real points
Sphere
Quadric classification
sphere
ellipsoid
hyperboloid of paraboloid
two sheets
Ruled quadrics:
hyperboloids
of one sheet
cone
two planes
Hierarchy of
transformations
group
transform
distortion
t
invariants properties
Projective
15dof
A
vT
Affine
12dof
A t
0 T 1
Similarity
7dof
s R t
0T 1
Euclidean
6dof
R t
0 T 1
Volume
Parallellism of planes,
Volume ratios, centroids,
The plane at infinity
A
t
1
T
A
0
0
0
1
X 12 X 22 X 32
X4
d d
Euclidean:
cos
d d d d
d d
cos
Projective:
d d d d
T
1
T
1 1
T
1
T
1
d1T d 2 0
T
2
T
2
(orthogonality=conjugacy)
I
Q T
0
*
0
0
8 dof
plane at infinity is the nullvector of
Angles:
1T Q* 2
cos
Q*
Q Q
T
1
T
2