Robert Collins CSE486, Penn State. Lecture 09: Stereo Algorithms

Similar documents
Robert Collins CSE586 CSE 586, Spring 2009 Advanced Computer Vision

Lecture 14: Basic Multi-View Geometry

Stereo Wrap + Motion. Computer Vision I. CSE252A Lecture 17

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

Lecture 6 Stereo Systems Multi-view geometry

CS5670: Computer Vision

1. Stereo Correspondence. (100 points)

A virtual tour of free viewpoint rendering

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

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

Lecture 14: Computer Vision

Stereo matching. Francesco Isgrò. 3D Reconstruction and Stereo p.1/21

Fundamentals of Stereo Vision Michael Bleyer LVA Stereo Vision

Stereo imaging ideal geometry

CS 4495/7495 Computer Vision Frank Dellaert, Fall 07. Dense Stereo Some Slides by Forsyth & Ponce, Jim Rehg, Sing Bing Kang

Dense 3D Reconstruction. Christiano Gava

Dense 3D Reconstruction. Christiano Gava

Problem Set 7 CMSC 426 Assigned Tuesday April 27, Due Tuesday, May 11

Human Body Recognition and Tracking: How the Kinect Works. Kinect RGB-D Camera. What the Kinect Does. How Kinect Works: Overview

CS 787: Assignment 4, Stereo Vision: Block Matching and Dynamic Programming Due: 12:00noon, Fri. Mar. 30, 2007.

Stereo vision. Many slides adapted from Steve Seitz

Maximum-Likelihood Stereo Correspondence using Field Programmable Gate Arrays

Stereo. Many slides adapted from Steve Seitz

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

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

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

Data Term. Michael Bleyer LVA Stereo Vision

Image Based Reconstruction II

Chaplin, Modern Times, 1936

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

Stereo Correspondence with Occlusions using Graph Cuts

Epipolar Geometry and Stereo Vision

Depth from two cameras: stereopsis

Segmentation Based Stereo. Michael Bleyer LVA Stereo Vision

Recall: Derivative of Gaussian Filter. Lecture 7: Correspondence Matching. Observe and Generalize. Observe and Generalize. Observe and Generalize

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

Subpixel accurate refinement of disparity maps using stereo correspondences

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

Epipolar Geometry CSE P576. Dr. Matthew Brown

Final project bits and pieces

BIL Computer Vision Apr 16, 2014

Computer Vision, Lecture 11

Epipolar Geometry and Stereo Vision

Depth from two cameras: stereopsis

Stereo Matching.

Announcements. Stereo Vision Wrapup & Intro Recognition

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

N-Views (1) Homographies and Projection

Stereo Vision II: Dense Stereo Matching

Lecture 10: Multi view geometry

Multiple View Geometry

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

Lecture 10 Dense 3D Reconstruction

What have we leaned so far?

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 Baseline Stereo

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

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

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

Geometric Reconstruction Dense reconstruction of scene geometry

Robert Collins CSE598G. Intro to Template Matching and the Lucas-Kanade Method

A New Parallel Implementation of DSI Based Disparity Computation Using CUDA

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

Depth from Stereo. Dominic Cheng February 7, 2018

Lecture 9 & 10: Stereo Vision

Integration of Multiple-baseline Color Stereo Vision with Focus and Defocus Analysis for 3D Shape Measurement

Introduction à la vision artificielle X

Rectification and Distortion Correction

Lecture 10 Multi-view Stereo (3D Dense Reconstruction) Davide Scaramuzza

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

STEREO BY TWO-LEVEL DYNAMIC PROGRAMMING

Binocular Stereo Vision. System 6 Introduction Is there a Wedge in this 3D scene?

Capturing, Modeling, Rendering 3D Structures

Recap from Previous Lecture

COMP 558 lecture 22 Dec. 1, 2010

EE795: Computer Vision and Intelligent Systems

Multiple View Geometry

Robert Collins CSE486, Penn State Lecture 08: Introduction to Stereo

Final Exam Study Guide CSE/EE 486 Fall 2007

Matching. Compare region of image to region of image. Today, simplest kind of matching. Intensities similar.

CS6670: Computer Vision

Does Color Really Help in Dense Stereo Matching?

MAPI Computer Vision. Multiple View Geometry

Camera Calibration. Schedule. Jesus J Caban. Note: You have until next Monday to let me know. ! Today:! Camera calibration

CONTENTS. High-Accuracy Stereo Depth Maps Using Structured Light. Yeojin Yoon

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

A New Approach for Stereo Matching Algorithm with Dynamic Programming

Computer Vision Projective Geometry and Calibration. Pinhole cameras

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

Fast Stereo Matching of Feature Links

Asymmetric 2 1 pass stereo matching algorithm for real images

Improving Border Localization of Multi-Baseline Stereo Using Border-Cut

(Sample) Final Exam with brief answers

Cameras and Stereo CSE 455. Linda Shapiro

Three-Dimensional Coordinate Systems

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

Stereo and structured light

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

Stereo: Disparity and Matching

Perception II: Pinhole camera and Stereo Vision

Transcription:

Lecture 09: Stereo Algorithms

left camera located at (0,0,0) Recall: Simple Stereo System Y y Image coords of point (X,Y,Z) Left Camera: x T x z (, ) y Z (, ) x (X,Y,Z) z X right camera located at (T x,0,0) Right Camera: Camps, PSU

Recall: Stereo Disparity Left camera Right camera Stereo Disparity depth baseline disparity Important equation!

Recall: Stereo Disparity Left camera Right camera Note: Depth and stereo disparity are inversely proportional depth disparity Important equation!

Stereo Example Left Image Right Image From Middlebury stereo evaluation page http://www.middlebury.edu/stereo/

Left image Stereo Example Disparity values (0-64) Right image Note how disparity is larger (brighter) for closer surfaces.

Computing Disparity Correspondence Problem: Determining which pixel in the right image corresponds to each pixel in the left image. Disp = x_coord(left) - x_coord(right) Recall our discussion of computing correspondences of image patches ( Lecture 7 ). SSD - sum of squared difference measure NCC - normalized cross correlation measure Camps, PSU

Epipolar Constraint Important Concept: For stereo matching, we don t have to search the whole 2D right image for a corresponding point. The epipolar constraint reduces the search space to a one-dimensional line.

Recall : Simple Stereo System y x T x z y x P z Epipolar line Left camera Right camera Same Y Coord!

Matching using Epipolar Lines Left Image Right Image For a patch in left image Compare with patches along same row in right image Match Score Values

Matching using Epipolar Lines Left Image Right Image Select patch with highest match score. Repeat for all pixels in left image. Match Score Values

Example: 5x5 windows NCC match score Computed disparities Black pixels: bad disparity values, or no matching patch in right image Ground truth

Occlusions: No matches Left image Right image

Effects of Patch Size 5x5 patches Smoother in some areas 11x11patches Loss of finer details

Adding Inter-Scanline Consistency So far, each left image patch has been matched independently along the right epipolar line. This can lead to errors. We would like to enforce some consistency among matches in the same row (scanline).

Disparity Space Image First we introduce the concept of DSI. The DSI for one row represents pairwise match scores between patches along that row in the left and right image. Pixels along right scanline Pixel j Pixels along left scanline Pixel i C(i,j) = Match score for patch centered at left pixel i with patch centered at right pixel j.

Disparity Space Image (DSI) Left Image Right Image Dissimilarity Values (1-NCC) or SSD

Disparity Space Image (DSI) Left Image Right Image Dissimilarity Values (1-NCC) or SSD

Disparity Space Image (DSI) Left Image Right Image Dissimilarity Values (1-NCC) or SSD

Disparity Space Image (DSI) Left Image DSI Dissimilarity Values Enter each vector of match scores as a column in the DSI

Disparity Space Image Left scanline Right scanline

Disparity Space Image Left scanline Right scanline Invalid entries due to constraint that disparity <= high value 64 in this case) Invalid entries due to constraint that disparity >= low value (0 in this case)

M cols in right scanline Disparity Space Image N cols in left scanline If we rearrange the diagonal band of valid values into a rectangular array (in this case of size 64 x N), that is what is traditionally known as the DSI However, I m going to keep the full image around, including invalid values (I think it is easier to understand the pixel coordinates involved) coordinate in left scanline (e.g. N) Disparity (e.g. 64) Disparity Space Image

Start DSI and Scanline Consistency Assigning disparities to all pixels in left scanline now amounts to finding a connected path through the DSI End

Lowest Cost Path We would like to choose the best path. Want one with lowest cost (Lowest sum of dissimilarity scores along the path)???

Constraints on Path It is common to impose an ordering constraint on the path. Intuitively, the path is not allowed to double back on itself.

Ordering Constraint A B C D A B C A B C D D A B C D A B C D D A B C Ordering constraint and its failure

Dealing with Occlusions Left scanline Right scanline

Dealing with Occlusions Left scanline Right scanline Occluded from right scanline Match Match Match Occluded from left scanline

An Optimal Scanline Strategy We want to find best path, taking into account ordering constraint and the possibility of occlusions. Algorithm we will discuss now is from Cox, Hingorani, Rao, Maggs, A Maximum Likelihood Stereo Algorithm, Computer Vision and Image Understanding, Vol 63(3), May 1996, pp.542-567.

Cox et.al. Stereo Matching Occluded from right i-1,j-1 i-1,j Occluded from left match match Occluded from left i,j-1 Occluded Three cases: from right Matching patches. Cost = dissimilarity score Occluded from right. Cost is some constant value. Occluded from left. Cost is some constant value. i,j C(i,j)= min([ C(i-1,j-1) + dissimilarity(i,j) C(i-1,j) + occlusionconstant, C(i,j-1) + occlusionconstant]);

Start Cox et.al. Stereo Matching Recap: want to find lowest cost path from upper left to lower right of DSI image. End At each point on the path we have three choices: step left, step down, step diagonally. Each choice has a well-defined cost associated with it. This problem just screams out for Dynamic Programming! (which, indeed, is how Cox et.al. solve the problem)

Robert Collins Real Scanline Example DSI DP cost matrix (cost of optimal path from each point to END) Every pixel in left column now is marked with either a disparity value, or an occlusion label. Proceed for every scanline in left image.

Result of DP alg Example Result without DP (independent pixels) Result of DP alg. Black pixels = occluded.

Occlusion Filling Simple trick for filling in gaps caused by occlusion. = left occluded Fill in left occluded pixels with value from the nearest valid pixel preceding it in the scanline. Similarly, for right occluded, look for valid pixel to the right.

Example Result of DP alg with occlusion filling.

Example Result of DP alg with occlusion filling. Result without DP (independent pixels)

Example Result of DP alg with occlusion filling. Ground truth

www.middlebury.edu/stereo/

State-of-the-Art Results Algorithm Results Ground truth J. Sun, Y. Li, S.B. Kang, and H.-Y. Shum. Symmetric stereo matching for occlusion handling. IEEE Conference on Computer Vision and Pattern Recognition, June 2005.