You are on page 1of 51

EECE 5639 Computer Vision I

Lecture
Geometric and Coordinate Systems Transformation
Hw 1 deadline has been extende
Next Clas
Color, Filtering

1
5

Euclidean (Rigid)

y y
θ
transform x’y’

)
1

ty

0
0 1 x tx x

equations matrix form


2
Similarity (scaled Euclidean)

y y x’y’ S
θ
transform

)
1

ty

0
0 1 x tx x

equations matrix form

3
Af ne

y y
x’ y’
transform
1

0
0 1 x x

equations matrix form

4
fi
Projective

y y
x’ y’
transform
1

0
0 1 x x
Note!

equations matrix form

5
Co-Vectors
l’
y T
x’

x l
Transforming line equations: x

6
Summary of 2D Transformations

7
Euclidean
Similarity
Affine
Projective
Summary of 2D Transformations

from R.Szeliski
12
Transformation Groups

A mathematical group G is composed of a set of elements


and an associative operator * such that:

1) The set is closed under operator *

2) There exists an identity element I such that

3) Each element A has an inverse A-1 such that

13

Example of a Group
Claim: translations matrices form a group under composition
(matrix multiplication operator)

Group element: matrices of form:

Operator: matrix multiplication *


Note: matrix multiplication is indeed associative
A * (B * C) = (A * B) * C

14


Translation Group (cont)

Verify: closed under composition

15
Translation Group (cont)
Verify: existence of identity element

? ?

16
Translation Group (cont)

Verify: existence of inverse for every element

? ?

17
Example2: Euclidean Group

Closed under composition

= =

Identity exists

Inverse Exists

Check it !

18
Transformation Groups
We have veri ed that translations form a group.

Why does it matter?

Groups are very well-behaved. When doing computations with


groups we can freely compose transformations and assume
inverses exist.

Example T1 state2 T2
state1 state3
?

19

fi

Transformation Groups
We have veri ed that translations form a group.

Why does it matter?

Groups are very well-behaved. When doing computations with


groups we can freely compose transformations and assume
inverses exist.

Inverse exists
T1 state2 T2-1
state1 state3
?

20

fi

Transformation Groups
We have veri ed that translations form a group.

Why does it matter?

Groups are very well-behaved. When doing computations with


groups we can freely compose transformations and assume
inverses exist.

Inverse exists Inverse exists


T1-1 state2 T2-1
state1 state3
?

21

fi

Transformation Groups
We have veri ed that translations form a group.

Why does it matter?

Groups are very well-behaved. When doing computations with


groups we can freely compose transformations and assume
inverses exist.

Inverse exists Inverse exists


T1-1 state2 T2-1
state1 state3
T1-1 * T2-1
closed under composition
22

fi

Hierarchy of Transformations

projective

affine
subgroup
hierarchy
similarity

Euclidean

23

Composition in a Hierarchy

projective
similarity * similarity = similarity
affine
similarity * affine = affine
similarity
Euclidean * affine = affine
Euclidean
any * projective = projective

24
Pinhole Camera Model

(Camera Coordinates)

P
y
Y x p
X f

Z
O

•Non-linear equations
•Any point on the ray OP has image p !!

25

3D to 2D Perspective Matrix Equation



(Camera Coordinates)

Using homogeneous coordinates:


X
x= f
Z
Y
y= f
Z

26
Perspective Matrix Equation

(Camera Coordinates)

27
28
Image (Film) Coord.
World Coord.
Camera Coord.

Pixel Coors.
More intrinsic parameters:
The CCD sensor is made of a rectangular grid nxm of photosensors
Each photosensor generates an analog signal that is digitized by a frame
grabber into an array of NxM pixels.

30
Intrinsic Parameters

NxN pixels Imaged Grid

nxn CCD elements mxn CCD elements


n:m aspect ratio n:n aspect ratio
31

A more complete Mint


In practice, we will assume that there is a
1-1 correspondence between CCD elements and pixels.

0 y0
<latexit sha1_base64="vpNCNLcSEH/Q4vbhOsOGBvAY7vs=">AAAB+nicbVDLSsNAFL3xWesr1aWbwSJ1VRIp6kYounFZwT6gDWUynbRDJw9mJpUY8yluXCji1i9x5984bbPQ1gMXDufcy733uBFnUlnWt7Gyura+sVnYKm7v7O7tm6WDlgxjQWiThDwUHRdLyllAm4opTjuRoNh3OW2745up355QIVkY3Kskoo6PhwHzGMFKS32zNEFXqOcJTNKkkqWPlaxvlq2qNQNaJnZOypCj0Te/eoOQxD4NFOFYyq5tRcpJsVCMcJoVe7GkESZjPKRdTQPsU+mks9MzdKKVAfJCoStQaKb+nkixL2Xiu7rTx2okF72p+J/XjZV36aQsiGJFAzJf5MUcqRBNc0ADJihRPNEEE8H0rYiMsM5B6bSKOgR78eVl0jqr2ufV2l2tXL/O4yjAERzDKdhwAXW4hQY0gcADPMMrvBlPxovxbnzMW1eMfOYQ/sD4/AFq4ZN6</latexit>

<latexit sha1_base64="qBR/YE8vynf/TAMP21HKNnHpv68=">AAAB+nicbVBNS8NAEJ34WetXqkcvi0XqqSRS1ItQ9OKxgv2AtpTNdtMu3WzC7katMT/FiwdFvPpLvPlv3LY5aOuDgcd7M8zM8yLOlHacb2tpeWV1bT23kd/c2t7ZtQt7DRXGktA6CXkoWx5WlDNB65ppTluRpDjwOG16o6uJ37yjUrFQ3OpxRLsBHgjmM4K1kXp2IUYXqONLTJKHUpo8ltKeXXTKzhRokbgZKUKGWs/+6vRDEgdUaMKxUm3XiXQ3wVIzwmma78SKRpiM8IC2DRU4oKqbTE9P0ZFR+sgPpSmh0VT9PZHgQKlx4JnOAOuhmvcm4n9eO9b+eTdhIoo1FWS2yI850iGa5ID6TFKi+dgQTCQztyIyxCYHbdLKmxDc+ZcXSeOk7J6WKzeVYvUyiyMHB3AIx+DCGVThGmpQBwL38Ayv8GY9WS/Wu/Uxa12yspl9+APr8wdnw5N4</latexit>

x
u= 0 v= 0
z z

Where cx and cy are the coordinates of the image center

32

PROBLEM: In general, the camera coordinate system is not aligned with the
world coordinate system

SOLUTION: Find a transformation between coordinate systems.

33
!

Coordinate Systems

World Camera Film Image


Coords. Coords. Coords. Coords.

Xw X x u
Yw Y y v
Zw Z

34

Coordinate Systems

World Camera Film Image


Coords. Coords. Coords. Coords.

Xw X x u
Yw Y y v
Zw Z

35

Coordinate Systems

World Camera Film Image


Coords. Coords. Coords. Coords.

Xw X x u
Yw Y y v
Zw Z

Rigid transformation: rotation & translation

36

3D Translation of Coordinate Systems


Translate by a vector t=(tx,ty,tz)’

37
3D Rotation of Coordinate Systems
CLOCKWISE Rotation around the coordinate axes (left hand):

38
Example

39
Example

40
Example

41
Example

R T

42
Example

Expressed in the
current
First, translate W to C coordinate
system!

43
Example

Expressed in the
First, translate W to C current
coordinate
system!
T

44
Example

Next, rotate W’ around Zw, 90o CCW ( -90o, CW)

45
Example

Next, rotate W’ around Zw, 90o CCW ( -90o, CW)


Rz T

46
Example

Next, rotate W’’ around Xw, 90o CCW ( -90o, CW)

47
Example

Next, rotate W’’ around Xw, 90o CCW ( -90o, CW)


Rx Rz T

48
Example

R T

49
Coordinate Systems

World Camera Film Image


Coords. Coords. Coords. Coords.

Xw X x u
Yw Y y v
Zw Z

Rigid transformation: rotation & translation

50

Pinhole Camera Model



(World Coordinates)

P
y Zw

Y x p
X f
Xw
Z T Yw
R O

51

You might also like