Presentation is loading. Please wait.

Presentation is loading. Please wait.

Geometry 3: Stereo Reconstruction Introduction to Computer Vision Ronen Basri Weizmann Institute of Science.

Similar presentations


Presentation on theme: "Geometry 3: Stereo Reconstruction Introduction to Computer Vision Ronen Basri Weizmann Institute of Science."— Presentation transcript:

1 Geometry 3: Stereo Reconstruction Introduction to Computer Vision Ronen Basri Weizmann Institute of Science

2 Material covered Pinhole camera model, perspective projection Two view geometry, general case: Epipolar geometry, the essential matrix Camera calibration, the fundamental matrix Two view geometry, degenerate cases Homography (planes, camera rotation) A taste of projective geometry Stereo vision: 3D reconstruction from two views Multi-view geometry, reconstruction through factorization

3 Summary of last lecture HomographyPerspective (calibrated) Perspective (uncalibrated) Orthographic Form PropertiesOne-to-one (group) Concentric epipolar lines Parallel epipolar lines DOFs 8(5) 8(7)4 Eqs/pnt 2111 Minimal configuration 45+ (8,linear)7+ (8,linear)4 DepthNoYes, up to scale Yes, projective structure Affine structure (third view required for Euclidean structure)

4 Camera rotation

5 Planar scene

6 Epipolar lines epipolar lines Baseline O O’ epipolar plane

7 Rectification Rectification: rotation and scaling of each camera’s coordinate frame to make the epipolar lines horizontal and equi-height, by bringing the two image planes to be parallel to the baseline Rectification is achieved by applying homography to each of the two images

8 Rectification Baseline O O’

9 Cyclopean coordinates

10 Disparity

11 The correspondence problem Stereo matching is ill-posed: Matching ambiguity: different regions may look similar

12 The correspondence problem Stereo matching is ill-posed: Matching ambiguity: different regions may look similar Specular reflectance: multiple depth values

13 Random dot stereogram Depth is perceived from a pair of random dot images Stereo perception is based solely on local information (low level)

14 Moving random dots

15 Compared elements for correspondence

16 Dynamic programming Each pair of epipolar lines is compared independently Local cost, sum of unary term and binary term Unary term: cost of a single match Binary term: cost of change of disparity (occlusion) Analogous to string matching (‘diff’ in Unix)

17 String matching Swing → String S t r i n g S w i n g Start End

18 String matching Cost: #substitutions + #insertions + #deletions S t r i n g S w i n g

19

20 Stereo with dynamic programming Shortest path in a grid Diagonals: constant disparity Moving along the diagonal – pay unary cost (cost of pixel match) Move sideways – pay binary cost, i.e. disparity change (occlusion, right or left) Cost prefers fronto-parallel planes. Penalty is paid for tilted planes

21 Dynamic programming on a grid Start

22 Probability interpretation: the Viterbi algorithm

23

24 Dynamic programming: pros and cons Advantages: Simple, efficient Achieves global optimum Generally works well Disadvantages:

25 Dynamic programming: pros and cons Advantages: Simple, efficient Achieves global optimum Generally works well Disadvantages: Works separately on each epipolar line, does not enforce smoothness across epipolars Prefers fronto-parallel planes Too local? (considers only immediate neighbors)

26 Markov random field

27 Iterated conditional modes (ICM)

28 Graph cuts: expansion moves

29 α-Expansion In any one round, expansion move allows each pixel to either change its state to α, or maintain its previous state Each round is implemented via max flow/min cut One iteration: apply expansion moves sequentially with all possible disparity values Repeat till convergence

30 α-Expansion

31 α-Expansion (1D example)

32

33

34

35

36

37

38

39 Common metrics

40 Reconstruction with graph-cuts Original Result Ground truth

41 A different application: detect skyline Input: one image, oriented with sky above Objective: find the skyline in the image Graph: grid Two states: sky, ground Unary (data) term: State = sky, low if blue, otherwise high State = ground, high if blue, otherwise low Binary term for vertical connections: If state(node)=sky then state(node above)=sky (infinity if not) If state(node)=ground then state(node below)= ground Solve with expansion move. This is a two state problem, and so graph cut finds the global optimum in one expansion move


Download ppt "Geometry 3: Stereo Reconstruction Introduction to Computer Vision Ronen Basri Weizmann Institute of Science."

Similar presentations


Ads by Google