Projective geometry of 2-space DLT alg HZ 4.1 Rectification HZ 2.7 Hierarchy of maps Invariants HZ 2.4 Projective transform HZ 2.3 Behaviour at infinity.

Slides:



Advertisements
Similar presentations
3D Geometry for Computer Graphics
Advertisements

The fundamental matrix F
Lecture 11: Two-view geometry
3D reconstruction.
Primitives Behaviour at infinity HZ 2.2 Projective DLT alg Invariants
Conics DLT alg HZ 4.1 Rectification HZ 2.7 Hierarchy of maps Invariants HZ 2.4 Projective transform HZ 2.3 Behaviour at infinity Primitives pt/line/conic.
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
Camera calibration and epipolar geometry
Structure from motion.
Multiple View Geometry
Parameter estimation class 5 Multiple View Geometry Comp Marc Pollefeys.
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
Epipolar Geometry and the Fundamental Matrix F
Lecture 21: Multiple-view geometry and structure from motion
3D reconstruction of cameras and structure x i = PX i x’ i = P’X i.
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Lecture 9: Image alignment CS4670: Computer Vision Noah Snavely
Multiple View Geometry Marc Pollefeys University of North Carolina at Chapel Hill Modified by Philippos Mordohai.
Single View Metrology Class 3. 3D photography course schedule (tentative) LectureExercise Sept 26Introduction- Oct. 3Geometry & Camera modelCamera calibration.
CMPUT 412 3D Computer Vision Presented by Azad Shademan Feb , 2007.
Previously Two view geometry: epipolar geometry Stereo vision: 3D reconstruction epipolar lines Baseline O O’ epipolar plane.
3D Geometry for Computer Graphics
Camera parameters Extrinisic parameters define location and orientation of camera reference frame with respect to world frame Intrinsic parameters define.
Structure Computation. How to compute the position of a point in 3- space given its image in two views and the camera matrices of those two views Use.
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
Computer vision: models, learning and inference
Image Stitching Ali Farhadi CSE 455
CSC 589 Lecture 22 Image Alignment and least square methods Bei Xiao American University April 13.
Lecture 12: Image alignment CS4670/5760: Computer Vision Kavita Bala
Recap of linear algebra: vectors, matrices, transformations, … Background knowledge for 3DM Marc van Kreveld.
Computing the Fundamental matrix Peter Praženica FMFI UK May 5, 2008.
Epipolar geometry The fundamental matrix and the tensor
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.
Homogeneous Coordinates (Projective Space) Let be a point in Euclidean space Change to homogeneous coordinates: Defined up to scale: Can go back to non-homogeneous.
Objects at infinity used in calibration
Multiview Geometry and Stereopsis. Inputs: two images of a scene (taken from 2 viewpoints). Output: Depth map. Inputs: multiple images of a scene. Output:
Day x: Infinity DLT alg HZ 4.1 Rectification HZ 2.7 Hierarchy of maps Invariants HZ 2.4 Projective transform HZ 2.3 Behaviour at infinity Primitives pt/line/conic.
تهیه کننده : نرگس مرعشی استاد راهنما : جناب آقای دکتر جمشید شنبه زاده.
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.
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.
Day x 5-10 minute quiz SVD demo review of metric rectification algorithm 1.build a 2x3 matrix A from orthog line pairs A = [L1M1, L1M2+L2M1, L2M2; L1’M1’,
A Flexible New Technique for Camera Calibration Zhengyou Zhang Sung Huh CSPS 643 Individual Presentation 1 February 25,
Auto-calibration we have just calibrated using a calibration object –another calibration object is the Tsai grid of Figure 7.1 on HZ182, which can be used.
Structure from Motion Paul Heckbert, Nov , Image-Based Modeling and Rendering.
Stereo March 8, 2007 Suggested Reading: Horn Chapter 13.
Parameter estimation class 5 Multiple View Geometry CPSC 689 Slides modified from Marc Pollefeys’ Comp
Camera Calibration Course web page: vision.cis.udel.edu/cv March 24, 2003  Lecture 17.
Projective 2D geometry course 2 Multiple View Geometry Comp Marc Pollefeys.
Lecture 16: Image alignment
55:148 Digital Image Processing Chapter 11 3D Vision, Geometry
CS4670 / 5670: Computer Vision Kavita Bala Lec 27: Stereo.
René Vidal and Xiaodong Fan Center for Imaging Science
Homogeneous Coordinates (Projective Space)
Lecture 7: Image alignment
Parameter estimation class 5
Two-view geometry Computer Vision Spring 2018, Lecture 10
Epipolar geometry.
Structure from motion Input: Output: (Tomasi and Kanade)
Estimating 2-view relationships
3D reconstruction class 11
Uncalibrated Geometry & Stratification
Reconstruction.
Lecture 8: Image alignment
Back to equations of geometric transformations
Structure from motion Input: Output: (Tomasi and Kanade)
Parameter estimation class 6
Presentation transcript:

Projective geometry of 2-space DLT alg HZ 4.1 Rectification HZ 2.7 Hierarchy of maps Invariants HZ 2.4 Projective transform HZ 2.3 Behaviour at infinity Primitives pt/line/conic HZ 2.2

Computing a homography given 2 images of a scene, we would like to compute the homography H that relates their pixels –excellent example of the system-of- equations approach to compute a matrix (the homography) as a null vector H is a 3x3 matrix with 8 dof (9 – 1) –Hx = x’ how will we solve for these 8 degrees of freedom? solve for H using 4 point correspondences (x 1,x 1 ’),..., (x 4,x 4 ’) –bootstrap from 4 matches to all matches how will we find 4 point correspondences? SIFT (later) can also rectify using these ideas (Fig 2.4) HZ87-88, HZ35, Figure 4.9a,b

Lessons of DLT using SIFT for feature detection and feature matching developing the linear system of equations appproach learning to precondition data learning how to solve least squares –we have learned how to solve for null space learning RANSAC

Cross product as matrix multiplication we know that cross product may be interpreted as a determinant it is even more useful to interpret it as a skew-symmetric matrix a x b = [0-a 2 a 1 ] [b 0 ] [a 2 0 -a 0 ] [b 1 ] [-a 1 a 0 0] [b 2 ] this is now a matrix multiplication and fits seamlessly into our algebraic schemes we abbreviate this matrix [a x ] so that a x b = [a x ] b cute: a is the null vector of [a x ] (there’s no avoiding null space!) mnemonic: lower triangle is a2,-a1,a0 later we will interpret cross product as a tensor! HZ581, Appendix A

Reducing H to a null space idea: use Hx i = x i ’ to solve for H Hx i = x i ’ (which is not true in projective space; think scale) becomes x i ’ x Hx i = 0 let x i ’ = (x i ’, y i ’, w i ’), and use the skew-symmetric representation: x i ’ x Hx i = [0- w i ’ y i ’] [h 1 t x i ] [w i ’ 0 -x i ’] [h 2 t x i ] [-y i ’ x i ’ 0] [h 3 t x i ]OR [0 -w i ’ y i ’] [x i t h 1 ] [w i ’ 0 -x i ’] [x i t h 2 ] = 0 [-y i ’ x i ’ 0] [x i t h 3 ]OR [0 -w i ’x i t y i ’x i t ] [h 1 ] [w i ’x i t 0 -x i ’x i t ] [h 2 ] = 0 [h 3 ]OR (having removed the 3 rd equation, since it is linearly dependent on the others) A i h = 0 –where A i is a 2x9 matrix and h is the row-major unrolling of H this interprets H as the null vector of a 2x9 matrix

Preamble to DLT algorithm Note: x i ’ * row1 + y i ’ * row2 = -w i ’ * row3 DLT (Direct Linear Transformation) algorithm uses this transformation of point correspondences into a solution for the homography H A i h = 0 encodes the restriction x i ’ x Hx i = 0 (x i ’ and Hx i are equivalent) –but now in the form of a linear system (no cross product, H isolated) set the projective coordinate w = 1 in all of the points collect 4 of these pt-correspondence matrices A i, yielding an 8x9 matrix A, with a one-dimensional null space solve Ah = 0 for null vector h using SVD (see above) notice how this reverses the point of view: change the typical “solve Hx i = x i ’ for x i “ into “solve Hx i = x i ’ for H” –translate the matrix into a vector by unrolling HZ88-89

DLT algorithm 1.Find 4 point correspondences between 2 images of the same scene. 2.Precondition (see below). 3.Build the matrix A i from each correspondence (x i, x i ’). 4.Combine A1,...,A4 into A. 5.Find A’s null vector [see above: last column of V in SVD of A]. 6.This is the homography matrix H (encoded in row-major unrolling) that maps between the two images.

Preconditioning essential to normalize the images before applying DLT algorithm let { (x i, x i ’): i = 1,...,n } be the point correspondences translate and scale both pointsets translate centroid of { x i } to origin scale new { x i } so that average {dist( x i, origin)} = sqrt(2) –motivation: typical point looks like (1,1) do likewise to {x i ’}, but entirely independently –translate centroid to origin and scale so avg dist from origin is \sqrt(2) this normalization ensures that changes in x, y and w have comparable effect –e.g., if (100,100,1) is a feature point, changes in w will have 100 times more effect than changes in x or y HZ

DLT with more than 4 correspondences we can solve for the homography using only 4 point correspondences, but SIFT will typically find many more if n>4 point correspondences are known, we can collect them into a 2n-by-9 matrix A unless these correspondences are calculated exactly (highly unlikely!), Ah=0 will not be solvable instead, minimize ||Ah|| subject to the constraint ||h||=1 –the constraint is added to avoid the zero solution this optimal solution is the last column of V in the singular value decomposition A = UDV^t –serendipitously, same technique as original DLT algorithm the vector h is reconstructed into H (see above) that is, DLT algorithm remains exactly the same with 4 replaced by n HZ90-91, 593

Outliers and noise it is better to use all of the computed correspondences, because some of them will be unreliable –cannot guess which 4 are reliable –can use RANSAC to determine the highly unreliable correspondences (the outliers) –then use all of the remaining (still noisy) correspondences –when data is noisy, better to use lots of data Who wants to be a millionaire? studio audience poll