Robot Vision SS 2007 Matthias Rüther 1 ROBOT VISION Lesson 6a: Shape from Stereo, short summary Matthias Rüther Slides partial courtesy of Marc Pollefeys.

Slides:



Advertisements
Similar presentations
Epipolar Geometry.
Advertisements

The fundamental matrix F
Lecture 11: Two-view geometry
3D reconstruction.
Robot Vision SS 2005 Matthias Rüther 1 ROBOT VISION Lesson 3: Projective Geometry Matthias Rüther Slides courtesy of Marc Pollefeys Department of Computer.
Two-View Geometry CS Sastry and Yang
Multiple View Reconstruction Class 24 Multiple View Geometry Comp Marc Pollefeys.
Lecture 8: Stereo.
Epipolar Geometry class 11 Multiple View Geometry Comp Marc Pollefeys.
Camera calibration and epipolar geometry
Multiple View Geometry
Robot Vision SS 2008 Matthias Rüther 1 ROBOT VISION Lesson 6: Shape from Stereo Matthias Rüther Slides partial courtesy of Marc Pollefeys Department of.
Epipolar Geometry Class 7 Read notes Feature tracking run iterative L-K warp & upsample Tracking Good features Multi-scale Transl. Affine.
3D reconstruction class 11
Jan-Michael Frahm, Philippos Mordohai
Computing F and rectification class 14 Multiple View Geometry Comp Marc Pollefeys.
Computing F Class 8 Read notes Section 4.2. C1C1 C2C2 l2l2  l1l1 e1e1 e2e2 Fundamental matrix (3x3 rank 2 matrix) 1.Computable from corresponding points.
Epipolar geometry. (i)Correspondence geometry: Given an image point x in the first view, how does this constrain the position of the corresponding point.
Uncalibrated Geometry & Stratification Sastry and Yang
Epipolar Geometry and the Fundamental Matrix F
Lecture 21: Multiple-view geometry and structure from motion
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Geometry
Multiple View Geometry Comp Marc Pollefeys
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Geometry
Multiple View Geometry
Two-view geometry Epipolar geometry F-matrix comp. 3D reconstruction Structure comp.
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Triangulation and Multi-View Geometry Class 9 Read notes Section 3.3, , 5.1 (if interested, read Triggs’s paper on MVG using tensor notation, see.
Assignment 2 Compute F automatically from image pair (putative matches, 8-point, 7-point, iterative, RANSAC, guided matching) (due by Wednesday 19/03/03)
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Reconstruction Class 23 Multiple View Geometry Comp Marc Pollefeys.
May 2004Stereo1 Introduction to Computer Vision CS / ECE 181B Tuesday, May 11, 2004  Multiple view geometry and stereo  Handout #6 available (check with.
CSE473/573 – Stereo Correspondence
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Multiple View Geometry
Epipolar geometry Class 5
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Epipolar geometry Class 5. Geometric Computer Vision course schedule (tentative) LectureExercise Sept 16Introduction- Sept 23Geometry & Camera modelCamera.
Multi-view geometry. Multi-view geometry problems Structure: Given projections of the same 3D point in two or more images, compute the 3D coordinates.
Computer vision: models, learning and inference
Lecture 11 Stereo Reconstruction I Lecture 11 Stereo Reconstruction I Mata kuliah: T Computer Vision Tahun: 2010.
Lecture 12 Stereo Reconstruction II Lecture 12 Stereo Reconstruction II Mata kuliah: T Computer Vision Tahun: 2010.
Projective cameras Motivation Elements of Projective Geometry Projective structure from motion Planches : –
Multiview Geometry and Stereopsis. Inputs: two images of a scene (taken from 2 viewpoints). Output: Depth map. Inputs: multiple images of a scene. Output:
Stereo Course web page: vision.cis.udel.edu/~cv April 11, 2003  Lecture 21.
1 Formation et Analyse d’Images Session 7 Daniela Hall 25 November 2004.
Two-view geometry Epipolar geometry F-matrix comp. 3D reconstruction
Computing F. Content Background: Projective geometry (2D, 3D), Parameter estimation, Algorithm evaluation. Single View: Camera model, Calibration, Single.
Parameter estimation. 2D homography Given a set of (x i,x i ’), compute H (x i ’=Hx i ) 3D to 2D camera projection Given a set of (X i,x i ), compute.
Geometry of Multiple Views
Raquel A. Romano 1 Scientific Computing Seminar May 12, 2004 Projective Geometry for Computer Vision Projective Geometry for Computer Vision Raquel A.
3D Reconstruction Using Image Sequence
Uncalibrated reconstruction Calibration with a rig Uncalibrated epipolar geometry Ambiguities in image formation Stratified reconstruction Autocalibration.
Structure from motion Multi-view geometry Affine structure from motion Projective structure from motion Planches : –
Parameter estimation class 5 Multiple View Geometry CPSC 689 Slides modified from Marc Pollefeys’ Comp
Lec 26: Fundamental Matrix CS4670 / 5670: Computer Vision Kavita Bala.
CS4670 / 5670: Computer Vision Kavita Bala Lec 27: Stereo.
Two-view geometry Computer Vision Spring 2018, Lecture 10
Epipolar geometry.
Epipolar Geometry class 11
3D Photography: Epipolar geometry
Multiple View Geometry Comp Marc Pollefeys
Estimating 2-view relationships
3D reconstruction class 11
Uncalibrated Geometry & Stratification
Two-view geometry Epipolar geometry F-matrix comp. 3D reconstruction
Presentation transcript:

Robot Vision SS 2007 Matthias Rüther 1 ROBOT VISION Lesson 6a: Shape from Stereo, short summary Matthias Rüther Slides partial courtesy of Marc Pollefeys Department of Computer Science University of North Carolina, Chapel Hill

Robot Vision SS 2007 Matthias Rüther 2 Shape from Stereo What do we want to do? Measure 3D point location from two images of the point (from different viewpoints).

Robot Vision SS 2007 Matthias Rüther 3 Shape from Stereo How? Acquire two images (simultaneously, if the scene is not stationary) Determine camera geometry Find homologous (corresponding) points, i.e. points in both images which are an image of the same world point. Triangulate homologous points, i.e. determine world point from homologous points and camera geometry

Robot Vision SS 2007 Matthias Rüther 4 (i)We have the camera geometry and an image point, how does this constrain the location of the corresponding image point in the second image? (Correspondence geometry) (ii)We have corresponding image points, how does this constrain camera geometry? (Motion) (iii)We have the camera geometry and corresponding image points, what are the 3D point coordinates? (Correspondence geometry) Questions

Robot Vision SS 2007 Matthias Rüther 5 What if only C, C’, x are known? Question i: Epipolar Geometry and F

Robot Vision SS 2007 Matthias Rüther 6 Family of planes  and lines l and l’ Intersection in e and e’ Epipolar Geometry

Robot Vision SS 2007 Matthias Rüther 7 algebraic representation of epipolar geometry we will see that mapping is (singular) correlation (i.e. projective mapping from points to lines) represented by the fundamental matrix F Question i: Epipolar Geometry and F

Robot Vision SS 2007 Matthias Rüther 8 geometric derivation mapping from 2-D to 1-D family (rank 2) The Fundamental Matrix (F)

Robot Vision SS 2007 Matthias Rüther 9 algebraic derivation (note: doesn’t work for C=C’  F=0) The Fundamental Matrix (F)

Robot Vision SS 2007 Matthias Rüther 10 correspondence condition The fundamental matrix satisfies the condition that for any pair of corresponding points x↔x ’ in the two images The Fundamental Matrix (F)

Robot Vision SS 2007 Matthias Rüther 11 Mapping of corresponding epipolar lines: derivation l,l’ epipolar lines, k line not through e  l’=F[k] x l and symmetrically l=F T [k’] x l’ (pick k=e, since e T e≠0) Epipolar Line Geometry

Robot Vision SS 2007 Matthias Rüther 12 Derivation based purely on projective concepts F invariant to transformations of projective 3-space unique not unique canonical form Invariance under projective transformation without derivation

Robot Vision SS 2007 Matthias Rüther 13 F matrix corresponds to P,P’ iff P’ T FP is skew-symmetric Possible choice: Canonical representation: Canonical cameras given F Arbitrary 3-vectorArbitrary scalar

Robot Vision SS 2007 Matthias Rüther 14 (only one solution where points is in front of both cameras) Reconstruction from E: four possible solutions

Robot Vision SS 2007 Matthias Rüther 15 C1C1 C2C2 l2l2 P l1l1 e1e1 e2e2 Fundamental matrix (3x3 rank 2 matrix) 1.Computable from corresponding points 2.Simplifies matching 3.Allows to detect wrong matches 4.Related to calibration Underlying structure in set of matches for rigid scenes l2l2 C1C1 m1m1 L1L1 m2m2 L2L2 M C2C2 m1m1 m2m2 C1C1 C2C2 l2l2 P l1l1 e1e1 e2e2 m1m1 L1L1 m2m2 L2L2 M l2l2 lT1lT1 Canonical representation: Epipolar Geometry

Robot Vision SS 2007 Matthias Rüther 16 given x i ↔x‘ i, compute P,P‘ and X i reconstruction problem: for all i without additional information possible up to projective ambiguity 3D reconstruction of cameras and structure

Robot Vision SS 2007 Matthias Rüther 17 (i)Compute F from correspondences (ii)Compute camera matrices from F (iii)Compute 3D point for each pair of corresponding points computation of F use x‘ i Fx i =0 equations, linear in coeff. F 8 points (linear), 7 points (non-linear), 8+ (least-squares) computation of camera matrices use triangulation compute intersection of two backprojected rays Outline of reconstruction

Robot Vision SS 2007 Matthias Rüther 18 Reconstruction ambiguity: projective

Robot Vision SS 2007 Matthias Rüther 19 If a set of point correspondences in two views determine the fundamental matrix uniquely, then the scene and cameras may be reconstructed from these correspondences alone, and any two such reconstructions from these correspondences are projectively equivalent  along same ray of P 2, idem for P ‘ 2 two possibilities: X 2 i = HX 1 i, or points along baseline key result: allows reconstruction from pair of uncalibrated images The projectove reconstruction theorem

Robot Vision SS 2007 Matthias Rüther 20

Robot Vision SS 2007 Matthias Rüther 21 (i)Projective reconstruction (ii)Affine reconstruction (iii)Metric reconstruction Stratified reconstruction

Robot Vision SS 2007 Matthias Rüther 22 use control points X E i with known coordinates to go from projective to metric (2 lin. eq. in H -1 per view, 3 for two views) Direct metric reconstruction using ground truth

Robot Vision SS 2007 Matthias Rüther 23 separate known from unknown (data) (unknowns) (linear) Computation of F: basic equation

Robot Vision SS 2007 Matthias Rüther 24 SVD from linearly computed F matrix (rank 3) Compute closest rank-2 approximation Imposing the singularity constraint

Robot Vision SS 2007 Matthias Rüther 25

Robot Vision SS 2007 Matthias Rüther 26 ~10000 ~100 1 ! Orders of magnitude difference Between column of data matrix  least-squares yields poor results The NOT normalized 8-point algorithm

Robot Vision SS 2007 Matthias Rüther 27 Transform image to ~[-1,1]x[-1,1] (0,0) (700,500) (700,0) (0,500) (1,-1) (0,0) (1,1)(-1,1) (-1,-1) Least squares yields good results (Hartley, PAMI´97) The normalized 8-point algorithm

Robot Vision SS 2007 Matthias Rüther 28 Maximum Likelihood Estimation (= least-squares for Gaussian noise) Parameterize: Initialize: normalized 8-point, (P,P‘) from F, reconstruct X i Minimize cost using Levenberg-Marquardt (preferably sparse LM, see book) (overparametrized) The Gold Standard Algorithm

Robot Vision SS 2007 Matthias Rüther 29 Examples

Robot Vision SS 2007 Matthias Rüther 30 Examples

Robot Vision SS 2007 Matthias Rüther 31 Examples

Robot Vision SS 2007 Matthias Rüther 32 1.Do not use unnormalized algorithms 2.Quick and easy to implement: 8-point normalized 3.Better: enforce rank-2 constraint during minimization 4.Best: Maximum Likelihood Estimation (minimal parameterization, sparse implementation) Recommendations

Robot Vision SS 2007 Matthias Rüther 33  Extract feature points to relate images  Required properties: –Well-defined (i.e. neigboring points should all be different) –Stable across views (i.e. same 3D point should be extracted as feature for neighboring viewpoints) The correspondence problem: feature points

Robot Vision SS 2007 Matthias Rüther 34 homogeneous edge corner M should have large eigenvalues (e.g.Harris&Stephens´88; Shi&Tomasi´94) Find points that differ as much as possible from all neighboring points Feature = local maxima (subpixel) of F( 1, 2 ) Feature points

Robot Vision SS 2007 Matthias Rüther 35 Select strongest features (e.g. 1000/image) Feature points

Robot Vision SS 2007 Matthias Rüther 36 Evaluate NCC for all features with similar coordinates Keep mutual best matches Still many wrong matches! ? Feature matching

Robot Vision SS 2007 Matthias Rüther Gives satisfying results for small image motions Similarity Example

Robot Vision SS 2007 Matthias Rüther 38 Step 1. Extract features Step 2. Compute a set of potential matches Step 3. do Step 3.1 select minimal sample (i.e. 8 matches) Step 3.2 compute F Step 3.3 determine inliers until  (#inliers,#samples)<95% #inliers90%80%70%60%50% #samples Step 4. Compute F based on all inliers Step 5. Look for additional matches Step 6. Refine F based on all correct matches (generate hypothesis) (verify hypothesis) RANSAC

Robot Vision SS 2007 Matthias Rüther 39 restrict search range to neighborhood of epipolar line (  1.5 pixels) relax disparity restriction (along epipolar line) Finding more matches

Robot Vision SS 2007 Matthias Rüther 40  Degenerate cases –Planar scene –Pure rotation  No unique solution –Remaining DOF filled by noise –Use simpler model (e.g. homography)  Model selection (Torr et al., ICCV´98, Kanatani, Akaike) –Compare H and F according to expected residual error (compensate for model complexity) Degenerate Cases

Robot Vision SS 2007 Matthias Rüther 41  Absence of sufficient features (no texture)  Repeated structure ambiguity (Schaffalitzky and Zisserman, BMVC‘98) Robust matcher also finds Robust matcher also finds support for wrong hypothesis support for wrong hypothesis solution: detect repetition solution: detect repetition More problems