Visual Odometry Tutorial
Visual Odometry Tutorial
University of Zurich
Fraundorfer, F., Scaramuzza, D., Visual Odometry: Part II - Matching, Robustness, and
Applications, IEEE Robotics and Automation Magazine, Volume 19, issue 1, 2012.
input output
In GPS-denied environments,
such as underwater and aerial,
VO has utmost importance
Image sequence
Feature detection
SIFT features tracks
Local optimization
Tk,k-1 Ck-1
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Ck+1
Ck
Tk+1,k
Tk,k-1
Ck-1
The final structure and camera poses are typically refined with an offline
optimization (i.e., bundle adjustment), whose computation time grows with the
number of images
Visual SLAM
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Brief history of VO
Problem formulation
Motion estimation
Robust estimation
Error propagation
Discussion
2004: VO used on a robot on another planet: Mars rovers Spirit and Opportunity
Problem formulation
Motion estimation
Robust estimation
Error propagation
Discussion
Tk,k-1
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Ck+1
Tk+1,k
Ck
Tk,k-1
Ck-1
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Ck+1
Tk+1,k
Ck
Tk,k-1
Ck-1
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
𝑪𝟎 𝑪𝟏 𝑪𝟑 𝑪𝟒 𝑪𝒏−𝟏 𝑪𝒏
...
Problem formulation
Motion estimation
Robust estimation
Error propagation
Discussion
p' z' z
f
1 1 1
z z' f
p' z' z
f
1 1
z z ' z' f
z' f
F C
p'
z
f
1 1
z z ' z' f
z' f
F C
Image plane
v
u
Image plane
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Always possible after the camera has been calibrated!
Problem formulation
Motion estimation
Robust estimation
Error propagation
Feature detection
Discussion
Feature matching
Motion estimation
2D-2D 3D-3D 3D-2D
Local optimization
...
epipolar plane
x1 x2
p1 y1 p2 y2
z1 z 2
E [t ] R essential matrix
Copyright of Davide Scaramuzza - [email protected] - https://sites.google.com/site/scarabotix/
Motion estimation
2D-2D 3D-3D 3D-2D
x1 x2
p1 y1 p2 y2 Image coordinates on the Unit sphere
z1 z 2
E [t ] R Essential matrix
...
Stereo vision has the advantage over monocular vision that both
motion and structure are computed in the absolute scale. It also
exhibits less drift.
When the distance to the scene is much larger than the stereo
baseline, stereo VO degenerates into monocular VO
Problem formulation
Motion estimation
Robust estimation
Error propagation
Feature detection
Discussion
Feature matching
Motion estimation
2D-2D 3D-3D 3D-2D
Local optimization
blur,
changes in view point and illumination
50
for
which the mathematical model of 100
the
feature detector or descriptor does not
account for 150
350
400
450
• Calculate model
parameters that fit the
data in the sample
• Calculate model
parameters that fit the
data in the sample
• Calculate error
function for each data
point
• Calculate model
parameters that fit the
data in the sample
• Calculate error
function for each data
point
• Calculate model
parameters that fit the
data in the sample
• Calculate error
function for each data
point
• Repeat sampling
• Calculate model
parameters that fit the
data in the sample
• Calculate error
function for each data
point
• Repeat sampling
log(1 p)
N
log(1 (1 ) s )
Why ?
General rule:
Minimum number of points = NDoF - 1
To reduce the number iterations, we should use a smaller number of points ( < 5 )
Is this possible?
Yes, if we exploit motion constraints!
D. Scaramuzza. 1-Point-RANSAC Structure from Motion for Vehicle-Mounted Cameras by Exploiting Non-holonomic
Constraints. International Journal of Computer Vision, Volume 95, Issue 1, 2011
Only 1 iteration
The most efficient algorithm for
removing outliers, up to 800 Hz
900
800
600
500
2-point RANSAC
400
300
200
Problem formulation
Motion estimation
Robust estimation
Error propagation
Feature detection
Discussion
Feature matching
Motion estimation
2D-2D 3D-3D 3D-2D
Local optimization
𝐶𝑘 = 𝑓(𝐶𝑘−1 , 𝑇𝑘 ) Ck+1
Ck
The combined covariance ∑𝑘 is Tk+1
Tk
Ck-1
Problem formulation
Motion estimation
Robust estimation
Error propagation
Feature detection
Discussion
Feature matching
Motion estimation
2D-2D 3D-3D 3D-2D
Local optimization
𝒎
So far we assumed that the transformations are between consecutive
frames
Transformations can be computed also between non-adjacent frames
𝑇𝑒𝑖𝑗 and can be used as additional constraints to improve cameras
poses by minimizing the following
𝒎
Similar to pose-optimization but it also optimizes 3D points
First observation
Make sure that you have many points (thoudsands) which cover
the image uniformly
Space exploration:
Planetary lander furing descent phase
Spirit and Opportunity Mars-exploration rovers
Since 2004, used VO in addition to dead-reckoning for
about 6 Km
Especially in preence of wheel slip
MAV navigation
European project SFLY
Vision-based MAVs at the Robotics and Perception Group
(see http://rpg.ifi.uzh.ch/research_mav.html )
Underwater vehicles
The sFly video can be seen at
http://youtu.be/_-p08o_oTO4
Automotive industry