Structure From Mo,on Ali Farhadi CSE 576 Several - - PowerPoint PPT Presentation

structure from mo on
SMART_READER_LITE
LIVE PREVIEW

Structure From Mo,on Ali Farhadi CSE 576 Several - - PowerPoint PPT Presentation

Structure From Mo,on Ali Farhadi CSE 576 Several slides from Steve Seitz, Rick Szeliski, Mar,al Hebert, and Noha Snavely Structure from mo,on


slide-1
SLIDE 1

Structure ¡From ¡Mo,on ¡

Ali ¡Farhadi ¡ CSE ¡576 ¡ ¡ ¡

Several ¡slides ¡from ¡Steve ¡Seitz, ¡Rick ¡Szeliski, ¡Mar,al ¡Hebert, ¡and ¡Noha ¡Snavely ¡

slide-2
SLIDE 2

Structure ¡from ¡mo,on ¡

Camera 1 Camera 2 Camera 3

R1,t1 ¡ R2,t2 ¡ R3,t3 ¡

p1 ¡ p4 ¡ p3 ¡ p2 ¡ p5 ¡ p6 ¡ p7 ¡

minimize

g (R, ¡T, ¡P) ¡

  • aka ¡“bundle ¡adjustment” (texts: ¡ ¡Zisserman; ¡Faugeras) ¡
slide-3
SLIDE 3
  • Given ¡point ¡x and ¡rota,on ¡and ¡transla,on ¡R, ¡t

¡

  • Minimize ¡sum ¡of ¡squared ¡reprojec,on ¡errors: ¡

¡ ¡ ¡ ¡

predicted image location

  • bserved

image location

SfM objective function

slide-4
SLIDE 4

Solving ¡structure ¡from ¡mo,on ¡

  • Minimizing ¡g is ¡difficult: ¡

– g ¡is ¡non-­‑linear ¡due ¡to ¡rota,ons, ¡perspec,ve ¡division ¡ – lots ¡of ¡parameters: ¡3 ¡for ¡each ¡3D ¡point, ¡6 ¡for ¡each ¡camera ¡ – difficult ¡to ¡ini,alize ¡ – gauge ¡ambiguity: ¡error ¡is ¡invariant ¡to ¡a ¡similarity ¡transform ¡(transla,on, ¡ rota,on, ¡uniform ¡scale) ¡ ¡

  • Many ¡techniques ¡use ¡non-­‑linear ¡least-­‑squares ¡
  • p,miza,on ¡(bundle adjustment) ¡

– Levenberg-­‑Marquardt ¡is ¡a ¡popular ¡algorithm ¡ – hWp://en.wikipedia.org/wiki/Levenberg-­‑Marquardt_algorithm ¡

  • Good ¡code ¡online ¡

– Bundler: ¡ ¡hWp://phototour.cs.washington.edu/bundler/ ¡ – Mul,core: ¡ ¡hWp://grail.cs.washington.edu/projects/mcba/ ¡

slide-5
SLIDE 5

Suppose ¡we ¡know ¡3D ¡points ¡and ¡affine ¡ camera ¡parameters ¡… ¡

¡then, ¡we ¡can ¡compute ¡the ¡observed ¡2d ¡ posi,ons ¡of ¡each ¡point ¡

[ ]

⎥ ⎥ ⎥ ⎥ ⎦ ⎤ ⎢ ⎢ ⎢ ⎢ ⎣ ⎡ = ⎥ ⎥ ⎥ ⎥ ⎦ ⎤ ⎢ ⎢ ⎢ ⎢ ⎣ ⎡

mn m m n n n m

x x x x x x x x x X X X A A A ˆ ˆ ˆ ˆ ˆ ˆ ˆ ˆ ˆ

2 1 2 22 21 1 12 11 2 1 2 1

  • Camera ¡Parameters ¡(2mx3) ¡

3D ¡Points ¡(3xn) ¡ 2D ¡Image ¡Points ¡(2mxn) ¡

slide-6
SLIDE 6

What ¡if ¡we ¡instead ¡observe ¡ corresponding ¡2d ¡image ¡points? ¡

¡

Can ¡we ¡recover ¡the ¡camera ¡parameters ¡and ¡3d ¡ points? ¡

cameras ¡(2 ¡m) ¡ points ¡(n) ¡

[ ]

n m mn m m n n

X X X A A A x x x x x x x x x D

  • 2

1 2 1 2 1 2 22 21 1 12 11

? ˆ ˆ ˆ ˆ ˆ ˆ ˆ ˆ ˆ ⎥ ⎥ ⎥ ⎥ ⎦ ⎤ ⎢ ⎢ ⎢ ⎢ ⎣ ⎡ ⇒ ⎥ ⎥ ⎥ ⎥ ⎦ ⎤ ⎢ ⎢ ⎢ ⎢ ⎣ ⎡ =

What ¡rank ¡is ¡the ¡matrix ¡of ¡2D ¡points? ¡

slide-7
SLIDE 7

Factorizing ¡the ¡measurement ¡matrix ¡

Source: ¡M. ¡Hebert ¡

slide-8
SLIDE 8

Factorizing ¡the ¡measurement ¡matrix ¡

  • Singular ¡value ¡decomposi,on ¡of ¡D: ¡

Source: ¡M. ¡Hebert ¡

slide-9
SLIDE 9

Factorizing ¡the ¡measurement ¡matrix ¡

  • Singular ¡value ¡decomposi,on ¡of ¡D: ¡

Source: ¡M. ¡Hebert ¡

slide-10
SLIDE 10

Factorizing ¡the ¡measurement ¡matrix ¡

  • Obtaining ¡a ¡factoriza,on ¡from ¡SVD: ¡

Source: ¡M. ¡Hebert ¡

slide-11
SLIDE 11

Factorizing ¡the ¡measurement ¡matrix ¡

  • Obtaining ¡a ¡factoriza,on ¡from ¡SVD: ¡

Source: ¡M. ¡Hebert ¡

This decomposition minimizes |D-MS|2

slide-12
SLIDE 12

Algorithm ¡summary ¡

  • Given: ¡m ¡images ¡and ¡n ¡features ¡xij ¡
  • For ¡each ¡image ¡i, ¡center ¡the ¡feature ¡coordinates ¡
  • Construct ¡a ¡2m ¡× ¡n ¡measurement ¡matrix ¡D: ¡

– Column ¡j ¡contains ¡the ¡projec,on ¡of ¡point ¡j ¡in ¡all ¡views ¡ – Row ¡i ¡contains ¡one ¡coordinate ¡of ¡the ¡projec,ons ¡of ¡all ¡ the ¡n ¡points ¡in ¡image ¡i ¡

  • Factorize ¡D: ¡

– Compute ¡SVD: ¡D ¡= ¡U ¡W ¡VT ¡ – Create ¡U3 ¡by ¡taking ¡the ¡first ¡3 ¡columns ¡of ¡U ¡ – Create ¡V3 ¡by ¡taking ¡the ¡first ¡3 ¡columns ¡of ¡V ¡ – Create ¡W3 ¡by ¡taking ¡the ¡upper ¡leh ¡3 ¡× ¡3 ¡block ¡of ¡W ¡

  • Create ¡the ¡mo,on ¡and ¡shape ¡matrices: ¡

– M ¡= ¡U3W3

½ ¡ ¡and ¡S ¡= ¡W3 ½ ¡V3 T ¡(or ¡M ¡= ¡U3 ¡and ¡S ¡= ¡W3V3 T) ¡

Source: ¡M. ¡Hebert ¡

slide-13
SLIDE 13

Structure ¡from ¡mo,on ¡

Camera 1 Camera 2 Camera 3

R1,t1 ¡ R2,t2 ¡ R3,t3 ¡

p1 ¡ p4 ¡ p3 ¡ p2 ¡ p5 ¡ p6 ¡ p7 ¡

minimize

g (R, ¡T, ¡P) ¡

  • aka ¡“bundle ¡adjustment” (texts: ¡ ¡Zisserman; ¡Faugeras) ¡
slide-14
SLIDE 14

Structure ¡from ¡mo,on ¡

Computed 3D structure Images on the Internet

slide-15
SLIDE 15
  • Photo ¡tourism ¡video: ¡ ¡hWp://www.youtube.com/watch?v=5Ji84zb2r8s ¡
  • Photosynth: ¡ ¡hWp://photosynth.net/ ¡
slide-16
SLIDE 16
slide-17
SLIDE 17
slide-18
SLIDE 18

Scene ¡reconstruc,on ¡

  • Automa,cally ¡es,mate ¡ ¡

– posi,on, ¡orienta,on, ¡and ¡focal ¡length ¡of ¡cameras ¡ – 3D ¡posi,ons ¡of ¡feature ¡points ¡

Feature ¡detec,on ¡ Pairwise ¡ feature ¡matching ¡ Incremental ¡ structure ¡ from ¡mo,on ¡ Correspondence ¡ es,ma,on ¡

slide-19
SLIDE 19

Feature ¡detec,on ¡

Detect ¡features ¡using ¡SIFT ¡[Lowe, ¡IJCV ¡2004] ¡

slide-20
SLIDE 20

Feature ¡detec,on ¡

Detect ¡features ¡using ¡SIFT ¡[Lowe, ¡IJCV ¡2004] ¡

slide-21
SLIDE 21

Feature ¡detec,on ¡

Detect ¡features ¡using ¡SIFT ¡[Lowe, ¡IJCV ¡2004] ¡

slide-22
SLIDE 22

Correspondence ¡es,ma,on ¡

  • Link ¡up ¡pairwise ¡matches ¡to ¡form ¡connected ¡components ¡of ¡

matches ¡across ¡several ¡images ¡

Image ¡1 ¡ Image ¡2 ¡ Image ¡3 ¡ Image ¡4 ¡

slide-23
SLIDE 23

Feature ¡matching ¡

Match ¡features ¡between ¡each ¡pair ¡of ¡images ¡

slide-24
SLIDE 24

Feature ¡matching ¡

Refine ¡matching ¡using ¡RANSAC ¡[Fischler ¡& ¡Bolles ¡1987] ¡

slide-25
SLIDE 25

Incremental ¡structure ¡from ¡mo,on ¡

slide-26
SLIDE 26

Incremental ¡structure ¡from ¡mo,on ¡

slide-27
SLIDE 27

Photo ¡Explorer ¡

slide-28
SLIDE 28
  • St. Peters (inside)

Trevi Fountain

  • St. Peters (outside)

Il Vittoriano Coliseum (inside) Coliseum (outside) Forum

slide-29
SLIDE 29

Naviga,on: ¡Prague ¡Old ¡Town ¡Square ¡

slide-30
SLIDE 30

Hierarchical ¡annota,ons ¡

slide-31
SLIDE 31

Locking ¡the ¡camera ¡(stabiliza,on) ¡

slide-32
SLIDE 32

Applica,ons ¡

slide-33
SLIDE 33

Community ¡photo ¡collec,ons ¡

  • “Wikipedia ¡for ¡photos” ¡– ¡visual ¡record ¡of ¡

world ¡through ¡community ¡of ¡ photographers ¡

– Geograph ¡Bri1sh ¡Isles ¡ hWp://www.geograph.org.uk/ ¡

  • Users ¡can ¡tag ¡and ¡comment ¡on ¡photos, ¡

link ¡to ¡other ¡content ¡

– World-­‑wide ¡telescope ¡

  • “Where ¡should ¡I ¡take ¡a ¡photo?” ¡

hWp://photocitygame.com/ ¡

¡

slide-34
SLIDE 34

Community ¡photo ¡collec,ons ¡

  • Leveraging ¡large ¡databases ¡of ¡photos, ¡large ¡

number ¡of ¡users ¡

– Annota,ons ¡/ ¡augmented ¡reality ¡

slide-35
SLIDE 35

Virtual ¡tour ¡guide ¡scenario ¡

  • St. ¡Peter’s ¡Basilica ¡
  • ¡ ¡Built: ¡1506-­‑1626 ¡
  • ¡ ¡hWp://en.wikipedia.org/wiki/St._Peter's_Basilica ¡
  • St. ¡Peter’s ¡Basilica ¡
  • ¡ ¡Built: ¡1506-­‑1626 ¡
slide-36
SLIDE 36

Rephotography ¡

Topographic ¡data ¡courtesy ¡USGS ¡