Recap: Features and filters. Recap: Grouping & fitting. Now: Multiple views 10/29/2008. Epipolar geometry & stereo vision. Why multiple views?

Similar documents
Computer Vision Lecture 17

Computer Vision Lecture 17

Project 4 Results. Representation. Data. Learning. Zachary, Hung-I, Paul, Emanuel. SIFT and HoG are popular and successful.

Think-Pair-Share. What visual or physiological cues help us to perceive 3D shape and depth?

Stereo: Disparity and Matching

Stereo. Outline. Multiple views 3/29/2017. Thurs Mar 30 Kristen Grauman UT Austin. Multi-view geometry, matching, invariant features, stereo vision

Stereo. 11/02/2012 CS129, Brown James Hays. Slides by Kristen Grauman

Miniature faking. In close-up photo, the depth of field is limited.

Mosaics wrapup & Stereo

Multi-View Geometry (Ch7 New book. Ch 10/11 old book)

Last time: Disparity. Lecture 11: Stereo II. Last time: Triangulation. Last time: Multi-view geometry. Last time: Epipolar geometry

Epipolar Geometry and Stereo Vision

Epipolar Geometry and Stereo Vision

There are many cues in monocular vision which suggests that vision in stereo starts very early from two similar 2D images. Lets see a few...

Multiple View Geometry

6.819 / 6.869: Advances in Computer Vision Antonio Torralba and Bill Freeman. Lecture 11 Geometry, Camera Calibration, and Stereo.

Image Rectification (Stereo) (New book: 7.2.1, old book: 11.1)

Announcements. Stereo

What have we leaned so far?

Chaplin, Modern Times, 1936

Announcements. Stereo

CS 4495 Computer Vision A. Bobick. Motion and Optic Flow. Stereo Matching

CS4495/6495 Introduction to Computer Vision. 3B-L3 Stereo correspondence

Final project bits and pieces

Geometry of Multiple views

Binocular stereo. Given a calibrated binocular stereo pair, fuse it to produce a depth image. Where does the depth information come from?

Epipolar Geometry and Stereo Vision

CS 4495 Computer Vision A. Bobick. Motion and Optic Flow. Stereo Matching

Stereo vision. Many slides adapted from Steve Seitz

Epipolar Geometry and Stereo Vision

Project 3 code & artifact due Tuesday Final project proposals due noon Wed (by ) Readings Szeliski, Chapter 10 (through 10.5)

Project 2 due today Project 3 out today. Readings Szeliski, Chapter 10 (through 10.5)

Today. Stereo (two view) reconstruction. Multiview geometry. Today. Multiview geometry. Computational Photography

Stereo II CSE 576. Ali Farhadi. Several slides from Larry Zitnick and Steve Seitz

CS 2770: Intro to Computer Vision. Multiple Views. Prof. Adriana Kovashka University of Pittsburgh March 14, 2017

Multiple View Geometry

Recap from Previous Lecture

Stereo CSE 576. Ali Farhadi. Several slides from Larry Zitnick and Steve Seitz

Lecture 14: Basic Multi-View Geometry

Stereo Vision. MAN-522 Computer Vision

CS5670: Computer Vision

Public Library, Stereoscopic Looking Room, Chicago, by Phillips, 1923

Lecture 9 & 10: Stereo Vision

Cameras and Stereo CSE 455. Linda Shapiro

CEng Computational Vision

Stereo and Epipolar geometry

Lecture 6 Stereo Systems Multi-view geometry

Computer Vision I. Announcement. Stereo Vision Outline. Stereo II. CSE252A Lecture 15

Camera Geometry II. COS 429 Princeton University

Dense 3D Reconstruction. Christiano Gava

Correspondence and Stereopsis. Original notes by W. Correa. Figures from [Forsyth & Ponce] and [Trucco & Verri]

Depth from two cameras: stereopsis

Lecture 9: Epipolar Geometry

Depth from two cameras: stereopsis

Lecture'9'&'10:'' Stereo'Vision'

Lecture 10: Multi-view geometry

BIL Computer Vision Apr 16, 2014

Fundamental matrix. Let p be a point in left image, p in right image. Epipolar relation. Epipolar mapping described by a 3x3 matrix F

Dense 3D Reconstruction. Christiano Gava

Stereo Vision A simple system. Dr. Gerhard Roth Winter 2012

Stereo. Many slides adapted from Steve Seitz

Colorado School of Mines. Computer Vision. Professor William Hoff Dept of Electrical Engineering &Computer Science.

Lecture 14: Computer Vision

Recovering structure from a single view Pinhole perspective projection

Lecture 6 Stereo Systems Multi- view geometry Professor Silvio Savarese Computational Vision and Geometry Lab Silvio Savarese Lecture 6-24-Jan-15

Depth. Common Classification Tasks. Example: AlexNet. Another Example: Inception. Another Example: Inception. Depth

7. The Geometry of Multi Views. Computer Engineering, i Sejong University. Dongil Han

Fundamentals of Stereo Vision Michael Bleyer LVA Stereo Vision

Announcements. Stereo Vision II. Midterm. Example: Helmholtz Stereo Depth + Normals + BRDF. Stereo

Machine vision. Summary # 11: Stereo vision and epipolar geometry. u l = λx. v l = λy

Multi-view stereo. Many slides adapted from S. Seitz

Why is computer vision difficult?

Basic distinctions. Definitions. Epstein (1965) familiar size experiment. Distance, depth, and 3D shape cues. Distance, depth, and 3D shape cues

Rectification and Disparity

calibrated coordinates Linear transformation pixel coordinates

Image Transfer Methods. Satya Prakash Mallick Jan 28 th, 2003

Perception II: Pinhole camera and Stereo Vision

Lecture 10: Multi view geometry

EECS 442 Computer vision. Stereo systems. Stereo vision Rectification Correspondence problem Active stereo vision systems

Colorado School of Mines. Computer Vision. Professor William Hoff Dept of Electrical Engineering &Computer Science.

Computer Vision I. Announcements. Random Dot Stereograms. Stereo III. CSE252A Lecture 16

Two-view geometry Computer Vision Spring 2018, Lecture 10

3D Sensing and Reconstruction Readings: Ch 12: , Ch 13: ,

But First: Multi-View Projective Geometry

Step-by-Step Model Buidling

Epipolar Geometry Prof. D. Stricker. With slides from A. Zisserman, S. Lazebnik, Seitz

Undergrad HTAs / TAs. Help me make the course better! HTA deadline today (! sorry) TA deadline March 21 st, opens March 15th

Reminder: Lecture 20: The Eight-Point Algorithm. Essential/Fundamental Matrix. E/F Matrix Summary. Computing F. Computing F from Point Matches

Stereo imaging ideal geometry

EE795: Computer Vision and Intelligent Systems

Flow Estimation. Min Bai. February 8, University of Toronto. Min Bai (UofT) Flow Estimation February 8, / 47

1 (5 max) 2 (10 max) 3 (20 max) 4 (30 max) 5 (10 max) 6 (15 extra max) total (75 max + 15 extra)

55:148 Digital Image Processing Chapter 11 3D Vision, Geometry

Final Exam Study Guide

Multi-stable Perception. Necker Cube

Stereo Epipolar Geometry for General Cameras. Sanja Fidler CSC420: Intro to Image Understanding 1 / 33

Finally: Motion and tracking. Motion 4/20/2011. CS 376 Lecture 24 Motion 1. Video. Uses of motion. Motion parallax. Motion field

Epipolar geometry. x x

Unit 3 Multiple View Geometry

Structure from Motion. Introduction to Computer Vision CSE 152 Lecture 10

Transcription:

Recap: Features and filters Epipolar geometry & stereo vision Tuesday, Oct 21 Kristen Grauman UT-Austin Transforming and describing images; textures, colors, edges Recap: Grouping & fitting Now: Multiple views Multi-view geometry, matching, invariant features, stereo vision Lowe Hartley and Zisserman Clustering, segmentation, fitting; what parts belong together? [fig from Shi et al] Fei-Fei Li Why multiple views? Structure and depth are inherently ambiguous from single views. Why multiple views? Structure and depth are inherently ambiguous from single views. P1 P2 P1 =P2 Optical center Images from Lana Lazebnik 1

Shading What cues help us to perceive 3d shape and depth? [Figure from Prados & Faugeras 2006] Focus/Defocus Texture [Figure from H. Jin and P. Favaro, 2002] [From A.M. Loh. The recovery of 3-D structure using visual texture patterns. PhD thesis] Perspective effects Motion Image credit: S. Seitz Figures from L. Zhang http://www.brainconnection.com/teasers/?main=illusion/motion-shape 2

Estimating scene shape Shape from X: Shading, Texture, Focus, Motion Stereo: shape from motion between two views infer 3d shape of scene from two (multiple) l images from different viewpoints Today Human stereopsis Stereograms Epipolar geometry and the epipolar constraint Case example with parallel optical axes General case with calibrated cameras Stereopsis Finding correspondences along the epipolar line Fixation, convergence Human stereopsis: disparity Disparity occurs when eyes fixate on one object; others appear at different visual angles Human stereopsis: disparity Random dot stereograms Julesz 1960: Do we identify local brightness patterns before fusion (monocular process) or after (binocular)? d=0 To test: pair of synthetic images obtained by randomly spraying black dots on white objects Disparity: d = r-l = D-F. Adapted from M. Pollefeys 3

Random dot stereograms Random dot stereograms Forsyth & Ponce Random dot stereograms Random dot stereograms When viewed monocularly, they appear random; when viewed stereoscopically, see 3d structure. Conclusion: human binocular fusion not directly associated with the physical retinas; must involve the central nervous system Imaginary cyclopean retina that combines the left and right image stimuli as a single unit From Palmer, Vision Science, MIT Press Autostereograms Autostereograms Exploit disparity as depth cue using single image (Single image random dot stereogram, Single image stereogram) Images from magiceye.com Images from magiceye.com 4

Stereo photography and stereo viewers Take two pictures of the same subject from two slightly different viewpoints and display so that each eye sees only one of the images. Invented by Sir Charles Wheatstone, 1838 Image courtesy of fisher-price.com http://www.johnsonshawmuseum.org http://www.johnsonshawmuseum.org Public Library, Stereoscopic Looking Room, Chicago, by Phillips, 1923 Depth with stereo: basic idea scene point optical center image plane http://www.well.com/~jimg/stereo/stereo_list.html Source: Steve Seitz 5

Depth with stereo: basic idea Camera calibration World frame Extrinsic parameters: Camera frame Reference frame Camera frame Intrinsic parameters: Image coordinates relative to camera Pixel coordinates Basic Principle: Triangulation Gives reconstruction as intersection of two rays Requires camera pose (calibration) point correspondence Extrinsic params: rotation matrix and translation vector Intrinsic params: focal length, pixel sizes (mm), image center point, radial distortion parameters We ll assume for now that these parameters are given and fixed. Source: Steve Seitz Today Human stereopsis Stereograms Epipolar geometry and the epipolar constraint Case example with parallel optical axes General case with calibrated cameras Stereopsis Finding correspondences along the epipolar line Geometry for a simple stereo system First, assuming parallel optical axes, known camera parameters (i.e., calibrated cameras): World point Geometry for a simple stereo system Assume parallel optical axes, known camera parameters (i.e., calibrated cameras). We can triangulate via: image point (left) Focal length optical center (left) baseline Depth of p image point (right) optical center (right) Similar triangles (p l, P, p r ) and (O l, P, O r ): T + x x Z f disparity l r = T Z T Z = f x r x l 6

Depth from disparity image I(x,y) Disparity map D(x,y) image I (x,y ) General case, with calibrated cameras The two cameras need not have parallel optical axes. (x,y )=(x+d(x,y), y) Vs. Stereo correspondence constraints Stereo correspondence constraints Given p in left image, where can corresponding point p be? Given p in left image, where can corresponding point p be? Stereo correspondence constraints Stereo correspondence constraints Geometry of two views allows us to constrain where the corresponding pixel for some image point in the first view must occur in the second view. epipolar line epipolar plane epipolar line Epipolar constraint: Why is this useful? Reduces correspondence problem to 1D search along conjugate epipolar lines Adapted from Steve Seitz 7

Epipolar geometry Epipolar geometry: terms Baseline: line joining the camera centers Epipole: point of intersection of baseline with the image plane Epipolar plane: plane containing baseline and world point Epipolar line: intersection of epipolar plane with the image plane Epipolar Plane Epipoles Baseline Epipolar Lines All epipolar lines intersect at the epipole An epipolar plane intersects the left and right image planes in epipolar lines Adapted from M. Pollefeys, UNC Epipolar constraint Example Potential matches for p have to lie on the corresponding epipolar line l. Potential matches for p have to lie on the corresponding epipolar line l. Source: M. Pollefeys http://www.ai.sri.com/~luong/research/meta3dviewer/epipolargeo.html Example: converging cameras Example: motion parallel with image plane As position of 3d point varies, epipolar lines rotate about the baseline Figure from Hartley & Zisserman Figure from Hartley & Zisserman 8

Example: forward motion e For a given stereo rig, how do we express the epipolar constraints algebraically? e Epipole has same coordinates in both images. Points move along lines radiating from e: Focus of expansion Figure from Hartley & Zisserman Stereo geometry, with calibrated cameras Rotation matrix Express 3d rotation as series of rotations around coordinate axes by angles α, β, γ If the rig is calibrated, we know : how to rotate and translate camera reference frame 1 to get to camera reference frame 2. Rotation: 3 x 3 matrix; translation: 3 vector. Overall rotation is product of these elementary rotations: R = R x R y R z 3d rigid transformation Stereo geometry, with calibrated cameras X = RX + T Camera-centered coordinate systems are related by known rotation R and translation T: X = RX + T 9

Cross product From geometry to algebra Vector cross product takes two vectors and returns a third vector that s perpendicular to both inputs. So here, c is perpendicular to both a and b, which means the dot product = 0. X' = RX + T T X = T RX + T T Normal to the plane = T RX ( T X ) = X ( T RX) = 0 X Matrix form of cross product From geometry to algebra Can be expressed as a matrix multiplication. X' = RX + T T X = T RX + T T Normal to the plane = T RX ( T X ) = X ( T RX) = 0 X Essential matrix Essential matrix and epipolar lines Let ( T ) = 0 X RX ( Tx ) = 0 X RX E = TxR X T EX = 0 p Τ Ep = 0 Epipolar constraint: if we observe point p in one image, then its position p in second image must satisfy this equation. Ep is the coordinate vector representing the epipolar line associated with point p This holds for the rays p and p that are parallel to the camera-centered position vectors X and X, so we have: p' T Ep = 0 E is called the essential matrix, which relates corresponding image points [Longuet-Higgins 1981] p E T is the coordinate vector representing the epipolar line associated with point p 10

Essential matrix: properties Relates image of corresponding points in both cameras, given rotation and translation Assuming intrinsic parameters are known E = TxR Essential matrix example: parallel cameras p Τ Ep = 0 R = I T = [ d,0,0] E = [T x]r = Τ 0 0 0 0 0 d 0 d 0 For the parallel cameras, image of any point must lie on same horizontal line in each image plane. Stereo image rectification image I(x,y) Disparity map D(x,y) image I (x,y ) In practice, it is convenient if image scanlines are the epipolar lines. (x,y )=(x+d(x,y),y) What about when cameras optical axes are not parallel? reproject image planes onto a common plane parallel to the line between optical centers pixel motion is horizontal after this transformation two homographies (3x3 transforms), one for each input image reprojection Adapted from Li Zhang C. Loop and Z. Zhang. Computing Rectifying Homographies for Stereo Vision. CVPR 1999. Stereo image rectification: example Today Human stereopsis Stereograms Epipolar geometry and the epipolar constraint Case example with parallel optical axes General case with calibrated cameras Stereopsis Finding correspondences along the epipolar line Source: Alyosha Efros 11

Stereo reconstruction: main steps Correspondence problem Calibrate cameras Rectify images Compute disparity Estimate depth Multiple match hypotheses satisfy epipolar constraint, but which is correct? Figure from Gee & Cipolla 1999 Correspondence problem To find matches in the image pair, we will assume Most scene points visible from both views Image regions for the matches are similar in appearance Additional correspondence constraints Similarity Uniqueness Ordering Disparity gradient Dense correspondence search Example: window search Data from University of Tsukuba For each epipolar line For each pixel / window in the left image compare with every pixel / window on same epipolar line in right image pick position with minimum match cost (e.g., SSD, correlation) Adapted from Li Zhang 12

Example: window search Effect of window size W = 3 W = 20 Want window large enough to have sufficient intensity variation, yet small enough to contain only pixels with about the same disparity. Figures from Li Zhang Sparse correspondence search Restrict search to sparse set of detected features Rather than pixel values (or lists of pixel values) use feature descriptor and an associated feature distance Still narrow search further by epipolar geometry Dense vs. sparse Sparse Efficiency Can have more reliable feature matches, less sensitive to illumination than raw pixels But, have to know enough to pick good features; sparse info Dense Simple process More depth estimates, can be useful for surface reconstruction But, breaks down in textureless regions anyway, raw pixel distances can be brittle, not good with very different viewpoints What would make good features? Difficulties in similarity constraint???? Uniqueness For opaque objects, up to one match in right image for every point in left image Untextured surfaces Occlusions Figure from Gee & Cipolla 1999 13

Ordering Points on same surface (opaque object) will be in same order in both views Disparity gradient Assume piecewise continuous surface, so want disparity estimates to be locally smooth Figure from Gee & Cipolla 1999 Figure from Gee & Cipolla 1999 Additional correspondence constraints Similarity Uniqueness Ordering Disparity gradient Possible sources of error? Low-contrast / textureless image regions Occlusions Camera calibration errors Violations of brightness constancy (e.g., specular reflections) Large motions Epipolar lines constrain the search to a line, and these appearance and ordering constraints further reduce the possible matches. Stereo reconstruction: main steps Stereo in machine vision systems Calibrate cameras Rectify images Compute disparity Estimate depth Left : The Stanford cart sports a single camera moving in discrete increments along a straight line and providing multiple snapshots of outdoor scenes Right : The INRIA mobile robot uses three cameras to map its environment Forsyth & Ponce 14

Depth for segmentation Depth for segmentation Edges in disparity in conjunction with image edges enhances contours found Danijela Markovic and Margrit Gelautz, Interactive Media Systems Group, Vienna University of Technology Danijela Markovic and Margrit Gelautz, Interactive Media Systems Group, Vienna University of Technology Virtual viewpoint video Virtual viewpoint video C. Zitnick et al, High-quality video view interpolation using a layered representation, SIGGRAPH 2004. http://research.microsoft.com/ivm/vvv/ Next Uncalibrated cameras Robust fitting 15