Single’View’Metrology’cis580/Spring2015/... · q 1...
Transcript of Single’View’Metrology’cis580/Spring2015/... · q 1...
![Page 1: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/1.jpg)
Single View Metrology
Slides taken from Steve Seitz, A. Efros
![Page 2: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/2.jpg)
Applica=ons of projec=ve geometry
– Criminisi et al., “Single View Metrology”, ICCV 1999 – Other methods
• Horry et al., “Tour Into the Picture”, SIGGRAPH 96 • Shum et al., CVPR 98 • ...
Vermeer’s Music Lesson
![Page 3: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/3.jpg)
1 2 3 4
1
2
3
4
Measurements on planes
Approach: unwarp then measure
What kind of warp is this?
• A Homography
![Page 4: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/4.jpg)
Image rec=fica=on, and measurement
![Page 5: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/5.jpg)
Vanishing points
• Vanishing point – projec=on of a point at infinity
image plane
camera center
ground plane
vanishing point
![Page 6: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/6.jpg)
Vanishing points (2D) image plane
camera center
line on ground plane
vanishing point
![Page 7: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/7.jpg)
Vanishing points
• Proper=es – Any two parallel lines have the same vanishing point – The ray from C through v point is parallel to the lines – An image may have more than one vanishing point
image plane
camera center C
line on ground plane
vanishing point V
line on ground plane
![Page 8: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/8.jpg)
Vanishing lines
• Mul=ple Vanishing Points – Any set of parallel lines on the plane define a vanishing point – The union of all of these vanishing points is the horizon line
• also called vanishing line – Note that different planes define different vanishing lines
v1 v2
![Page 9: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/9.jpg)
Compu=ng vanishing lines
• Proper=es – l is intersec=on of horizontal plane through C with image plane – Compute l from two sets of parallel lines on ground plane – All points at same height as C project to l – Provides way of comparing height of objects in the scene
ground plane
l C
![Page 10: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/10.jpg)
Fun with vanishing points
![Page 11: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/11.jpg)
Perspec=ve cues
![Page 12: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/12.jpg)
Perspec=ve cues
![Page 13: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/13.jpg)
Perspec=ve cues
![Page 14: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/14.jpg)
Comparing heights Vanishing
Point
![Page 15: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/15.jpg)
Measuring height
1
2
3
4
5 5.4
2.8
3.3
Camera height
![Page 16: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/16.jpg)
q1
Compu=ng vanishing points (from lines)
• Intersect p1q1 with p2q2
v
p1
p2
q2
Least squares version
• Better to use more than two lines and compute the “closest” point of intersection
• See notes by Bob Collins for one good way of doing this: – http://www-2.cs.cmu.edu/~ph/869/www/notes/vanishing.txt
![Page 17: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/17.jpg)
Vanishingpoint
Vanishingline
Vanishingpoint
Vertical vanishingpoint
(at infinity)
Criminisi ’99
![Page 18: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/18.jpg)
C
Measuring height without a ruler
ground plane
Compute Y from image measurements • Need more than vanishing points to do this
Y
![Page 19: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/19.jpg)
Measuring height
RH
vz
r
b
t
H
b0
t0
vvx vy
vanishing line (horizon)
![Page 20: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/20.jpg)
Measuring height vz
r
b
t0
vx vy
vanishing line (horizon)
v
t0
m0
What if the point on the ground plane b0 is not known?
• Here the guy is standing on the box
• Use one side of the box to help find b0 as shown above
b0
t1
b1
![Page 21: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/21.jpg)
What if vz is not infinity?
![Page 22: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/22.jpg)
![Page 23: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/23.jpg)
The cross ra=o • A Projec=ve Invariant
– Something that does not change under projec=ve transforma=ons (including perspec=ve projec=on)
P1 P2
P3 P4
1423
2413
PPPPPPPP
−−
−−
The cross-ratio of 4 collinear points
Can permute the point ordering • 4! = 24 different orders (but only 6 distinct values)
This is the fundamental invariant of projective geometry
⎥⎥⎥⎥
⎦
⎤
⎢⎢⎢⎢
⎣
⎡
=
1i
i
i
i ZYX
P
3421
2431
PPPPPPPP
−−
−−
![Page 24: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/24.jpg)
vZ
r t
b
tvbrrvbt−−
−−
Z
Z
image cross ratio
Measuring height
B (bottom of object)
T (top of object)
R (reference point)
ground plane
H C
TBRRBT
−∞−
−∞−
scene cross ratio
∞
⎥⎥⎥⎥
⎦
⎤
⎢⎢⎢⎢
⎣
⎡
=
1ZYX
P⎥⎥⎥
⎦
⎤
⎢⎢⎢
⎣
⎡
=
1yx
pscene points represented as image points as
RH
=
RH
=
R
![Page 25: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/25.jpg)
Measuring height
RH
vz
r
b
t
R
H
Z
Z=
−−
−−
tvbr
rvbt
image cross ratio
H
b0
t0
vvx vy
vanishing line (horizon)
![Page 26: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/26.jpg)
Measuring heights of people
Here we go !
reference185.3 cm
![Page 27: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/27.jpg)
Forensic Science: measuring heights of suspects
Vanishing line
Refe
ren
ce h
eig
ht
Reference height
![Page 28: Single’View’Metrology’cis580/Spring2015/... · q 1 Compu=ng’vanishing’points’(from’lines)’ • Intersectp 1 q 1 ’with’p 2 q 2’’ v p 1 p 2 q 2 Least squares](https://reader036.fdocuments.in/reader036/viewer/2022081617/60463d2d62760643de3ce554/html5/thumbnails/28.jpg)
Assessing geometric accuracy
Flagellation, Piero della Francesca
Estimated relative heights
Are the heights of the 2 groups of people consistent with each other?