Single-view modeling, Part 2 CS4670/5670: Computer Vision Noah Snavely.

Slides:



Advertisements
Similar presentations
Single-view geometry Odilon Redon, Cyclops, 1914.
Advertisements

Single-view Metrology and Camera Calibration
Computer Vision, Robert Pless
Last 4 lectures Camera Structure HDR Image Filtering Image Transform.
More Mosaic Madness : Computational Photography Alexei Efros, CMU, Fall 2011 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen from.
RANSAC and mosaic wrap-up cs195g: Computational Photography James Hays, Brown, Spring 2010 © Jeffrey Martin (jeffrey-martin.com) most slides from Steve.
Features CSE 455, Winter 2010 February 1, Neel Joshi, CSE 455, Winter Review From Last Time.
Single-view metrology
CS6670: Computer Vision Noah Snavely Lecture 17: Stereo
Lecture 19: Single-view modeling CS6670: Computer Vision Noah Snavely.
list – let me know if you have NOT been getting mail Assignment hand in procedure –web page –at least 3 panoramas: »(1) sample sequence, (2) w/Kaidan,
Lecture 5: Projection CS6670: Computer Vision Noah Snavely.
Uncalibrated Geometry & Stratification Sastry and Yang
Scene Modeling for a Single View : Computational Photography Alexei Efros, CMU, Fall 2005 René MAGRITTE Portrait d'Edward James …with a lot of slides.
Announcements Project 2 questions Midterm out on Thursday
Projective geometry Slides from Steve Seitz and Daniel DeMenthon
Lecture 11: Structure from motion CS6670: Computer Vision Noah Snavely.
Lecture 20: Light, color, and reflectance CS6670: Computer Vision Noah Snavely.
Lecture 15: Single-view modeling CS6670: Computer Vision Noah Snavely.
Panorama signups Panorama project issues? Nalwa handout Announcements.
Lecture 16: Single-view modeling, Part 2 CS6670: Computer Vision Noah Snavely.
Camera calibration and single view metrology Class 4 Read Zhang’s paper on calibration
Single-view geometry Odilon Redon, Cyclops, 1914.
Panoramas and Calibration : Rendering and Image Processing Alexei Efros …with a lot of slides stolen from Steve Seitz and Rick Szeliski.
Camera Calibration from Planar Patterns Homework 2 Help SessionCS223bStanford University Mitul Saha (courtesy: Jean-Yves Bouguet, Intel)
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 02/26/15 1.
CSE 576, Spring 2008Projective Geometry1 Lecture slides by Steve Seitz (mostly) Lecture presented by Rick Szeliski.
Camera parameters Extrinisic parameters define location and orientation of camera reference frame with respect to world frame Intrinsic parameters define.
Scene Modeling for a Single View : Computational Photography Alexei Efros, CMU, Spring 2010 René MAGRITTE Portrait d'Edward James …with a lot of.
Lecture 12: Structure from motion CS6670: Computer Vision Noah Snavely.
VZvZ r t b image cross ratio Measuring height B (bottom of object) T (top of object) R (reference point) ground plane H C scene cross ratio  scene points.
Today: Calibration What are the camera parameters?
Single-view Metrology and Cameras Computational Photography Derek Hoiem, University of Illinois 10/8/13.
Single-view metrology
Projective Geometry and Single View Modeling CSE 455, Winter 2010 January 29, 2010 Ames Room.
776 Computer Vision Jan-Michael Frahm, Enrique Dunn Spring 2013.
Automatic Camera Calibration
Lecture 12: Image alignment CS4670/5760: Computer Vision Kavita Bala
Last Lecture (optical center) origin principal point P (X,Y,Z) p (x,y) x y.
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 01/25/11 1.
Camera calibration Digital Visual Effects Yung-Yu Chuang with slides by Richard Szeliski, Steve Seitz,, Fred Pighin and Marc Pollefyes.
Single View Geometry Course web page: vision.cis.udel.edu/cv April 9, 2003  Lecture 20.
Project 2 –contact your partner to coordinate ASAP –more work than the last project (> 1 week) –you should have signed up for panorama kitssigned up –sign.
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.
Peripheral drift illusion. Multiple views Hartley and Zisserman Lowe stereo vision structure from motion optical flow.
Single-view geometry Odilon Redon, Cyclops, 1914.
Single-view Metrology and Cameras Computational Photography Derek Hoiem, University of Illinois 10/06/15.
Last Two Lectures Panoramic Image Stitching
More with Pinhole + Single-view Metrology
Single-view geometry Odilon Redon, Cyclops, 1914.
Project 1 Due NOW Project 2 out today –Help session at end of class Announcements.
Announcements No midterm Project 3 will be done in pairs same partners as for project 2.
Project 2 went out on Tuesday You should have a partner You should have signed up for a panorama kit Announcements.
Calibrating a single camera
Lec 23: Single View Modeling
Single-view metrology
More Mosaic Madness © Jeffrey Martin (jeffrey-martin.com)
Depth from disparity (x´,y´)=(x+D(x,y), y)
Digital Visual Effects, Spring 2007 Yung-Yu Chuang 2007/4/17
Scene Modeling for a Single View
Digital Visual Effects, Spring 2006 Yung-Yu Chuang 2005/4/19
Digital Visual Effects, Spring 2008 Yung-Yu Chuang 2008/4/15
Digital Visual Effects Yung-Yu Chuang
Projective geometry Readings
Noah Snavely.
Announcements list – let me know if you have NOT been getting mail
Multi-view geometry.
Announcements Project 2 extension: Friday, Feb 8
Presentation transcript:

Single-view modeling, Part 2 CS4670/5670: Computer Vision Noah Snavely

Projective geometry Readings – Mundy, J.L. and Zisserman, A., Geometric Invariance in Computer Vision, Appendix: Projective Geometry for Machine Vision, MIT Press, Cambridge, MA, 1992, (read , 23.10) available online: Ames Room

Announcements Midterm to be handed in Thursday by 5pm Please hand it back at my office, Upson 4157

Three point perspective

Vanishing lines Multiple Vanishing Points – Any set of parallel lines on the plane define a vanishing point – The union of all of these vanishing points is the horizon line also called vanishing line – Note that different planes (can) define different vanishing lines v1v1 v2v2

Vanishing lines Multiple Vanishing Points – Any set of parallel lines on the plane define a vanishing point – The union of all of these vanishing points is the horizon line also called vanishing line – Note that different planes (can) define different vanishing lines

Computing vanishing points V P0P0 D

Properties – P  is a point at infinity, v is its projection – Depends only on line direction – Parallel lines P 0 + tD, P 1 + tD intersect at P  V P0P0 D

Computing vanishing lines Properties – l is intersection of horizontal plane through C with image plane – Compute l from two sets of parallel lines on ground plane – All points at same height as C project to l points higher than C project above l – Provides way of comparing height of objects in the scene ground plane l C v1v1 v2v2 l

Fun with vanishing points

Perspective cues

Comparing heights VanishingPoint

Measuring height Camera height How high is the camera?

q1q1 Computing vanishing points (from lines) Intersect p 1 q 1 with p 2 q 2 v p1p1 p2p2 q2q2 Least squares version Better to use more than two lines and compute the “closest” point of intersection See notes by Bob Collins for one good way of doing this:Bob Collins –

C Measuring height without a ruler ground plane Compute Z from image measurements Need more than vanishing points to do this Z

The cross ratio A Projective Invariant – Something that does not change under projective transformations (including perspective projection) P1P1 P2P2 P3P3 P4P4 The cross-ratio of 4 collinear points Can permute the point ordering 4! = 24 different orders (but only 6 distinct values) This is the fundamental invariant of projective geometry

vZvZ r t b image cross ratio Measuring height B (bottom of object) T (top of object) R (reference point) ground plane H C scene cross ratio  scene points represented as image points as R

Measuring height RH vzvz r b t image cross ratio H b0b0 t0t0 v vxvx vyvy vanishing line (horizon)

vzvz r b t0t0 vxvx vyvy v t0t0 m0m0 What if the point on the ground plane b 0 is not known? Here the guy is standing on the box, height of box is known Use one side of the box to help find b 0 as shown above b0b0 t1t1 b1b1 Measuring height

3D Modeling from a photograph St. Jerome in his Study, H. Steenwick

3D Modeling from a photograph

Flagellation, Piero della Francesca

3D Modeling from a photograph video by Antonio Criminisi

3D Modeling from a photograph

Camera calibration Goal: estimate the camera parameters – Version 1: solve for projection matrix Version 2: solve for camera parameters separately –intrinsics (focal length, principle point, pixel size) –extrinsics (rotation angles, translation) –radial distortion

Vanishing points and projection matrix = v x (X vanishing point) Z3Y2, similarly, v π v π  Not So Fast! We only know v’s up to a scale factor Can fully specify by providing 3 reference points

Calibration using a reference object Place a known object in the scene – identify correspondence between image and scene – compute mapping from scene to image Issues must know geometry very accurately must know 3D->2D correspondence

Chromaglyphs Courtesy of Bruce Culbertson, HP Labs

Estimating the projection matrix Place a known object in the scene – identify correspondence between image and scene – compute mapping from scene to image

Direct linear calibration

Can solve for m ij by linear least squares use eigenvector trick that we used for homographies

Direct linear calibration Advantage: – Very simple to formulate and solve Disadvantages: – Doesn’t tell you the camera parameters – Doesn’t model radial distortion – Hard to impose constraints (e.g., known f) – Doesn’t minimize the right error function For these reasons, nonlinear methods are preferred Define error function E between projected 3D points and image positions –E is nonlinear function of intrinsics, extrinsics, radial distortion Minimize E using nonlinear optimization techniques

Alternative: multi-plane calibration Images courtesy Jean-Yves Bouguet, Intel Corp. Advantage Only requires a plane Don’t have to know positions/orientations Good code available online! (including in OpenCV) –Matlab version by Jean-Yves Bouget: –Zhengyou Zhang’s web site:

Some Related Techniques Image-Based Modeling and Photo Editing – Mok et al., SIGGRAPH 2001 – Single View Modeling of Free-Form Scenes – Zhang et al., CVPR 2001 – Tour Into The Picture – Anjyo et al., SIGGRAPH 1997 –