3D Computer Vision and Video Computing 3D Vision Lecture 14 Stereo Vision (I) CSC 59866CD Fall 2004 Zhigang Zhu, NAC 8/203A

Slides:



Advertisements
Similar presentations
Lecture 11: Two-view geometry
Advertisements

3D reconstruction.
MASKS © 2004 Invitation to 3D vision Lecture 7 Step-by-Step Model Buidling.
Two-view geometry.
Lecture 8: Stereo.
Camera calibration and epipolar geometry
3D Computer Vision and Video Computing 3D Vision Topic 3 of Part II Stereo Vision CSc I6716 Spring 2011 Zhigang Zhu, City College of New York
Structure from motion.
Computer Vision : CISC 4/689
Stanford CS223B Computer Vision, Winter 2005 Lecture 5: Stereo I Sebastian Thrun, Stanford Rick Szeliski, Microsoft Hendrik Dahlkamp and Dan Morris, Stanford.
Stanford CS223B Computer Vision, Winter 2006 Lecture 5 Stereo I
The Fundamental Matrix F
Epipolar geometry. (i)Correspondence geometry: Given an image point x in the first view, how does this constrain the position of the corresponding point.
Structure from motion. Multiple-view geometry questions Scene geometry (structure): Given 2D point matches in two or more images, where are the corresponding.
Uncalibrated Geometry & Stratification Sastry and Yang
Lecture 21: Multiple-view geometry and structure from motion
Stereo and Multiview Sequence Processing. Outline Stereopsis Stereo Imaging Principle Disparity Estimation Intermediate View Synthesis Stereo Sequence.
Computer Vision : CISC 4/689
Lecture 20: Two-view geometry CS6670: Computer Vision Noah Snavely.
3D Computer Vision and Video Computing 3D Vision Topic 4 of Part II Stereo Vision CSc I6716 Spring 2008 Zhigang Zhu, City College of New York
3D Computer Vision and Video Computing 3D Vision Lecture 15 Stereo Vision (II) CSC 59866CD Fall 2004 Zhigang Zhu, NAC 8/203A
© 2004 by Davi GeigerComputer Vision March 2004 L1.1 Binocular Stereo Left Image Right Image.
May 2004Stereo1 Introduction to Computer Vision CS / ECE 181B Tuesday, May 11, 2004  Multiple view geometry and stereo  Handout #6 available (check with.
Lec 21: Fundamental Matrix
CSE473/573 – Stereo Correspondence
Computer Vision : CISC 4/689 CREDITS Rasmussen, UBC (Jim Little), Seitz (U. of Wash.), Camps (Penn. State), UC, UMD (Jacobs), UNC, CUNY.
Camera parameters Extrinisic parameters define location and orientation of camera reference frame with respect to world frame Intrinsic parameters define.
Stereo Sebastian Thrun, Gary Bradski, Daniel Russakoff Stanford CS223B Computer Vision (with slides by James Rehg and.
3-D Scene u u’u’ Study the mathematical relations between corresponding image points. “Corresponding” means originated from the same 3D point. Objective.
CSE 6367 Computer Vision Stereo Reconstruction Camera Coordinate Transformations “Everything should be made as simple as possible, but not simpler.” Albert.
Multi-view geometry. Multi-view geometry problems Structure: Given projections of the same 3D point in two or more images, compute the 3D coordinates.
Automatic Camera Calibration
Epipolar Geometry and Stereo Vision Computer Vision CS 543 / ECE 549 University of Illinois Derek Hoiem 03/05/15 Many slides adapted from Lana Lazebnik,
Computer vision: models, learning and inference
Lecture 11 Stereo Reconstruction I Lecture 11 Stereo Reconstruction I Mata kuliah: T Computer Vision Tahun: 2010.
Multi-view geometry.
1 Preview At least two views are required to access the depth of a scene point and in turn to reconstruct scene structure Multiple views can be obtained.
Geometric Camera Models and Camera Calibration
Shape from Stereo  Disparity between two images  Photogrammetry  Finding Corresponding Points Correlation based methods Feature based methods.
Lecture 04 22/11/2011 Shai Avidan הבהרה : החומר המחייב הוא החומר הנלמד בכיתה ולא זה המופיע / לא מופיע במצגת.
Multiview Geometry and Stereopsis. Inputs: two images of a scene (taken from 2 viewpoints). Output: Depth map. Inputs: multiple images of a scene. Output:
Announcements Project 3 due Thursday by 11:59pm Demos on Friday; signup on CMS Prelim to be distributed in class Friday, due Wednesday by the beginning.
Computer Vision Stereo Vision. Bahadir K. Gunturk2 Pinhole Camera.
Geometry of Multiple Views
CSE 185 Introduction to Computer Vision Stereo. Taken at the same time or sequential in time stereo vision structure from motion optical flow Multiple.
Bahadir K. Gunturk1 Phase Correlation Bahadir K. Gunturk2 Phase Correlation Take cross correlation Take inverse Fourier transform  Location of the impulse.
Two-view geometry. Epipolar Plane – plane containing baseline (1D family) Epipoles = intersections of baseline with image planes = projections of the.
stereo Outline : Remind class of 3d geometry Introduction
Feature Matching. Feature Space Outlier Rejection.
Jochen Triesch, UC San Diego, 1 Stereo Outline: parallel camera axes convergent axes, epipolar geometry correspondence.
Computer vision: models, learning and inference M Ahad Multiple Cameras
Geometry Reconstruction March 22, Fundamental Matrix An important problem: Determine the epipolar geometry. That is, the correspondence between.
Stereo March 8, 2007 Suggested Reading: Horn Chapter 13.
Lec 26: Fundamental Matrix CS4670 / 5670: Computer Vision Kavita Bala.
Correspondence and Stereopsis. Introduction Disparity – Informally: difference between two pictures – Allows us to gain a strong sense of depth Stereopsis.
CSE 185 Introduction to Computer Vision Stereo 2.
Multiview geometry ECE 847: Digital Image Processing Stan Birchfield Clemson University.
Multi-view geometry. Multi-view geometry problems Structure: Given projections of the same 3D point in two or more images, compute the 3D coordinates.
© 2005 Yusuf Akgul Gebze Institute of Technology Department of Computer Engineering Computer Vision Stereo.
55:148 Digital Image Processing Chapter 11 3D Vision, Geometry
3D Vision Topic 3 of Part II Stereo Vision CSc I6716 Fall 2009
Two-view geometry Computer Vision Spring 2018, Lecture 10
Epipolar geometry.
Topic 7 of Part 2 Stereo Vision (II)
Reconstruction.
3D Vision Topic 4 of Part II Stereo Vision CSc I6716 Fall 2005
Two-view geometry.
Course 6 Stereo.
Two-view geometry.
Multi-view geometry.
Presentation transcript:

3D Computer Vision and Video Computing 3D Vision Lecture 14 Stereo Vision (I) CSC 59866CD Fall 2004 Zhigang Zhu, NAC 8/203A Capstone2004/Capstone_Sequence2004.html

3D Computer Vision and Video Computing Stereo Vision n Problem l Infer 3D structure of a scene from two or more images taken from different viewpoints n Two primary Sub-problems l Correspondence problem (stereo match) -> disparity map n Similarity instead of identity n Occlusion problem: some parts of the scene are visible only in one eye l Reconstruction problem -> 3D n What we need to know about the cameras’ parameters n Often a stereo calibration problem n Lectures on Stereo Vision l Stereo Geometry – Epipolar Geometry (*) l Correspondence Problem (*) – Two classes of approaches l 3D Reconstruction Problems – Three approaches

3D Computer Vision and Video Computing A Stereo Pair n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D CMU CIL Stereo Dataset : Castle sequence ? 3D?

3D Computer Vision and Video Computing More Images… n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D

3D Computer Vision and Video Computing More Images… n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D

3D Computer Vision and Video Computing More Images… n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D

3D Computer Vision and Video Computing More Images… n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D

3D Computer Vision and Video Computing More Images… n Problems l Correspondence problem (stereo match) -> disparity map l Reconstruction problem -> 3D

3D Computer Vision and Video Computing Lecture Outline n A Simple Stereo Vision System l Disparity Equation l Depth Resolution l Fixated Stereo System n Zero-disparity Horopter n Epipolar Geometry l Epipolar lines – Where to search correspondences n Epipolar Plane, Epipolar Lines and Epipoles n l Essential Matrix and Fundamental Matrix n Computing E & F by the Eight-Point Algorithm n Computing the Epipoles n Stereo Rectification

3D Computer Vision and Video Computing Stereo Geometry n Converging Axes – Usual setup of human eyes n Depth obtained by triangulation n Correspondence problem: p l and p r correspond to the left and right projections of P, respectively. P(X,Y,Z)

3D Computer Vision and Video Computing A Simple Stereo System Z w =0 LEFT CAMERA Left image: reference Right image: target RIGHT CAMERA Elevation Z w disparity Depth Z baseline

3D Computer Vision and Video Computing Disparity Equation P(X,Y,Z) p l (x l,y l ) Optical Center O l f = focal length Image plane LEFT CAMERA B = Baseline Depth Stereo system with parallel optical axes f = focal length Optical Center O r p r (x r,y r ) Image plane RIGHT CAMERA Disparity: dx = x r - x l

3D Computer Vision and Video Computing Disparity vs. Baseline P(X,Y,Z) p l (x l,y l ) Optical Center O l f = focal length Image plane LEFT CAMERA B = Baseline Depth f = focal length Optical Center O r p r (x r,y r ) Image plane RIGHT CAMERA Disparity dx = x r - x l Stereo system with parallel optical axes

3D Computer Vision and Video Computing Depth Accuracy n Given the same image localization error l Angle of cones in the figure n Depth Accuracy (Depth Resolution) vs. Baseline l Depth Error  1/B (Baseline length) l PROS of Longer baseline, n better depth estimation l CONS n smaller common FOV n Correspondence harder due to occlusion n Depth Accuracy (Depth Resolution) vs. Depth l Disparity (>0)  1/ Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation n An Example l f = 16 x 512/8 pixels, B = 0.5 m l Depth error vs. depth Z2Z2 Two viewpoints Z2>Z1Z2>Z1 Z1Z1 Z1Z1 OlOl OrOr Absolute error Relative error

3D Computer Vision and Video Computing Stereo with Converging Cameras n Stereo with Parallel Axes l Short baseline n large common FOV n large depth error l Long baseline n small depth error n small common FOV n More occlusion problems n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases FOV Leftright

3D Computer Vision and Video Computing Stereo with Converging Cameras n Stereo with Parallel Axes l Short baseline n large common FOV n large depth error l Long baseline n small depth error n small common FOV n More occlusion problems n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases FOV Leftright

3D Computer Vision and Video Computing Stereo with Converging Cameras n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases n Disparity properties l Disparity uses angle instead of distance l Zero disparity at fixation point n and the Zero-disparity horopter l Disparity increases with the distance of objects from the fixation points n >0 : outside of the horopter n <0 : inside the horopter n Depth Accuracy vs. Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation FOV Leftright  Fixation point

3D Computer Vision and Video Computing  Stereo with Converging Cameras n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases n Disparity properties l Disparity uses angle instead of distance l Zero disparity at fixation point n and the Zero-disparity horopter l Disparity increases with the distance of objects from the fixation points n >0 : outside of the horopter n <0 : inside the horopter n Depth Accuracy vs. Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation Leftright Fixation point ll rr  r =  l d  = 0 Horopter

3D Computer Vision and Video Computing  Stereo with Converging Cameras n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases n Disparity properties l Disparity uses angle instead of distance l Zero disparity at fixation point n and the Zero-disparity horopter l Disparity increases with the distance of objects from the fixation points n >0 : outside of the horopter n <0 : inside the horopter n Depth Accuracy vs. Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation Leftright Fixation point ll rr  r >  l d  > 0 Horopter

3D Computer Vision and Video Computing Stereo with Converging Cameras n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases n Disparity properties l Disparity uses angle instead of distance l Zero disparity at fixation point n and the Zero-disparity horopter l Disparity increases with the distance of objects from the fixation points n >0 : outside of the horopter n <0 : inside the horopter n Depth Accuracy vs. Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation Leftright Fixation point LL rr  r <  l d  < 0 Horopter

3D Computer Vision and Video Computing Stereo with Converging Cameras n Two optical axes intersect at the Fixation Point converging angle  l The common FOV Increases n Disparity properties l Disparity uses angle instead of distance l Zero disparity at fixation point n and the Zero-disparity horopter l Disparity increases with the distance of objects from the fixation points n >0 : outside of the horopter n <0 : inside the horopter n Depth Accuracy vs. Depth l Depth Error  Depth 2 l Nearer the point, better the depth estimation Leftright Fixation point ll rr  d  Horopter

3D Computer Vision and Video Computing Parameters of a Stereo System n Intrinsic Parameters l Characterize the transformation from camera to pixel coordinate systems of each camera l Focal length, image center, aspect ratio n Extrinsic parameters l Describe the relative position and orientation of the two cameras l Rotation matrix R and translation vector T p l p r P OlOl OrOr XlXl XrXr PlPl PrPr flfl frfr ZlZl YlYl ZrZr YrYr R, T

3D Computer Vision and Video Computing Epipolar Geometry n Notations l P l =(X l, Y l, Z l ), P r =(X r, Y r, Z r ) n Vectors of the same 3-D point P, in the left and right camera coordinate systems respectively l Extrinsic Parameters n Translation Vector T = (O r -O l ) n Rotation Matrix R l p l =(x l, y l, z l ), p r =(x r, y r, z r ) n Projections of P on the left and right image plane respectively n For all image points, we have z l =f l, z r =f r p l p r P OlOl OrOr XlXl XrXr PlPl PrPr flfl frfr ZlZl YlYl ZrZr YrYr R, T

3D Computer Vision and Video Computing Epipolar Geometry n Motivation: where to search correspondences? l Epipolar Plane n A plane going through point P and the centers of projection (COPs) of the two cameras l Conjugated Epipolar Lines n Lines where epipolar plane intersects the image planes l Epipoles n The image in one camera of the COP of the other n Epipolar Constraint l Corresponding points must lie on conjugated epipolar lines p l p r P OlOl OrOr elel erer PlPl PrPr Epipolar Plane Epipolar Lines Epipoles

3D Computer Vision and Video Computing Essential Matrix n Equation of the epipolar plane l Co-planarity condition of vectors P l, T and P l -T n Essential Matrix E = RS l 3x3 matrix constructed from R and T (extrinsic only) n Rank (E) = 2, two equal nonzero singular values Rank (R) =3 Rank (S) =2

3D Computer Vision and Video Computing Essential Matrix n Essential Matrix E = RS l A natural link between the stereo point pair and the extrinsic parameters of the stereo system n One correspondence -> a linear equation of 9 entries n Given 8 pairs of (pl, pr) -> E l Mapping between points and epipolar lines we are looking for n Given p l, E -> p r on the projective line in the right plane n Equation represents the epipolar line of either pr (or pl) in the right (or left) image n Note: l pl, pr are in the camera coordinate system, not pixel coordinates that we can measure

3D Computer Vision and Video Computing Fundamental Matrix n Mapping between points and epipolar lines in the pixel coordinate systems l With no prior knowledge on the stereo system n From Camera to Pixels: Matrices of intrinsic parameters n Questions: l What are fx, fy, ox, oy ? l How to measure p l in images? Rank (M int ) =3

3D Computer Vision and Video Computing Fundamental Matrix n Fundamental Matrix l Rank (F) = 2 l Encodes info on both intrinsic and extrinsic parameters l Enables full reconstruction of the epipolar geometry l In pixel coordinate systems without any knowledge of the intrinsic and extrinsic parameters l Linear equation of the 9 entries of F

3D Computer Vision and Video Computing Computing F: The Eight-point Algorithm n Input: n point correspondences ( n >= 8) l Construct homogeneous system Ax= 0 from n x = (f 11,f 12,,f 13, f 21,f 22,f 23 f 31,f 32, f 33 ) : entries in F n Each correspondence give one equation n A is a nx9 matrix l Obtain estimate F^ by SVD of A n x (up to a scale) is column of V corresponding to the least singular value l Enforce singularity constraint: since Rank (F) = 2 n Compute SVD of F^ n Set the smallest singular value to 0: D -> D’ n Correct estimate of F : n Output: the estimate of the fundamental matrix, F’ n Similarly we can compute E given intrinsic parameters

3D Computer Vision and Video Computing Locating the Epipoles from F n Input: Fundamental Matrix F l Find the SVD of F l The epipole e l is the column of V corresponding to the null singular value (as shown above) l The epipole e r is the column of U corresponding to the null singular value n Output: Epipole e l and e r e l lies on all the epipolar lines of the left image F is not identically zero For every p r p l p r P OlOl OrOr elel erer PlPl PrPr Epipolar Plane Epipolar Lines Epipoles

3D Computer Vision and Video Computing Stereo Rectification n Rectification l Given a stereo pair, the intrinsic and extrinsic parameters, find the image transformation to achieve a stereo system of horizontal epipolar lines l A simple algorithm: Assuming calibrated stereo cameras p’ l r P OlOl OrOr X’ r PlPl PrPr Z’ l Y’ l Y’ r TX’ l Z’ r n Stereo System with Parallel Optical Axes n Epipoles are at infinity n Horizontal epipolar lines

3D Computer Vision and Video Computing Stereo Rectification n Algorithm l Rotate both left and right camera so that they share the same X axis : O r -O l = T l Define a rotation matrix R rect for the left camera l Rotation Matrix for the right camera is R rect R T l Rotation can be implemented by image transformation p l p r P OlOl OrOr XlXl XrXr PlPl PrPr ZlZl YlYl ZrZr YrYr R, T TX’ l X l ’ = T, Y l ’ = X l ’xZ l, Z’ l = X l ’xY l ’

3D Computer Vision and Video Computing Stereo Rectification n Algorithm l Rotate both left and right camera so that they share the same X axis : O r -O l = T l Define a rotation matrix R rect for the left camera l Rotation Matrix for the right camera is R rect R T l Rotation can be implemented by image transformation p l p r P OlOl OrOr XlXl XrXr PlPl PrPr ZlZl YlYl ZrZr YrYr R, T TX’ l X l ’ = T, Y l ’ = X l ’xZ l, Z’ l = X l ’xY l ’

3D Computer Vision and Video Computing Stereo Rectification n Algorithm l Rotate both left and right camera so that they share the same X axis : O r -O l = T l Define a rotation matrix R rect for the left camera l Rotation Matrix for the right camera is R rect R T l Rotation can be implemented by image transformation ZrZr p’ l r P OlOl OrOr X’ r PlPl PrPr Z’ l Y’ l Y’ r R, T TX’ l T’ = (B, 0, 0), P’ r = P’ l – T’

3D Computer Vision and Video Computing Next n Two Primary Sub-problems in Stereo Vision l Correspondence problem l 3D reconstruction from stereo Stereo Vision (II)