Paris town hall.

Slides:



Advertisements
Similar presentations
C280, Computer Vision Prof. Trevor Darrell Lecture 2: Image Formation.
Advertisements

Single-view Metrology and Camera Calibration
Computer Vision, Robert Pless
The Camera : Computational Photography Alexei Efros, CMU, Fall 2006.
CS 691 Computational Photography Instructor: Gianfranco Doretto 3D to 2D Projections.
Computer Vision CS 776 Spring 2014 Cameras & Photogrammetry 1 Prof. Alex Berg (Slide credits to many folks on individual slides)
Study the mathematical relations between corresponding image points.
The Camera CS194: Image Manipulation & Computational Photography Alexei Efros, UC Berkeley, Fall 2014.
Computer vision. Camera Calibration Camera Calibration ToolBox – Intrinsic parameters Focal length: The focal length in pixels is stored in the.
Camera Models A camera is a mapping between the 3D world and a 2D image The principal camera of interest is central projection.
Single-view metrology
Geometry of Images Pinhole camera, projection A taste of projective geometry Two view geometry:  Homography  Epipolar geometry, the essential matrix.
Announcements. Projection Today’s Readings Nalwa 2.1.
Lecture 5: Projection CS6670: Computer Vision Noah Snavely.
Announcements Mailing list (you should have received messages) Project 1 additional test sequences online Talk today on “Lightfield photography” by Ren.
CS485/685 Computer Vision Prof. George Bebis
Computer Vision - A Modern Approach
Announcements Mailing list Project 1 test the turnin procedure *this week* (make sure it works) vote on best artifacts in next week’s class Project 2 groups.
Computer Vision : CISC4/689
Lecture 13: Projection, Part 2
Lecture 12: Projection CS4670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Lecture 6: Image Warping and Projection CS6670: Computer Vision Noah Snavely.
The Pinhole Camera Model
CS223b, Jana Kosecka Rigid Body Motion and Image Formation.
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 02/26/15 1.
CS4670 / 5670: Computer Vision KavitaBala Lecture 15: Projection “The School of Athens,” Raphael.
The Camera : Computational Photography Alexei Efros, CMU, Fall 2008.
Scene Modeling for a Single View : Computational Photography Alexei Efros, CMU, Spring 2010 René MAGRITTE Portrait d'Edward James …with a lot of.
Cameras, lenses, and calibration
Perspective projection
EEM 561 Machine Vision Week 10 :Image Formation and Cameras
Single-view Metrology and Cameras Computational Photography Derek Hoiem, University of Illinois 10/8/13.
Northeastern University, Fall 2005 CSG242: Computational Photography Ramesh Raskar Mitsubishi Electric Research Labs Northeastern University September.
Single-view metrology
Single-view modeling, Part 2 CS4670/5670: Computer Vision Noah Snavely.
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
776 Computer Vision Jan-Michael Frahm Fall Camera.
Geometric Models & Camera Calibration
Recap from Wednesday Two strategies for realistic rendering capture real world data synthesize from bottom up Both have existed for 500 years. Both are.
776 Computer Vision Jan-Michael Frahm, Enrique Dunn Spring 2013.
Single-view Metrology and Camera Calibration Computer Vision Derek Hoiem, University of Illinois 01/25/11 1.
CS559: Computer Graphics Lecture 9: Projection Li Zhang Spring 2008.
Peripheral drift illusion. Multiple views Hartley and Zisserman Lowe stereo vision structure from motion optical flow.
Computational Photography Derek Hoiem, University of Illinois
Single-view geometry Odilon Redon, Cyclops, 1914.
CS-498 Computer Vision Week 7, Day 2 Camera Parameters Intrinsic Calibration  Linear  Radial Distortion (Extrinsic Calibration?) 1.
Single-view Metrology and Cameras Computational Photography Derek Hoiem, University of Illinois 10/06/15.
Single-view 3D Reconstruction
12/24/2015 A.Aruna/Assistant professor/IT/SNSCE 1.
More with Pinhole + Single-view Metrology
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Lecture 18: Cameras CS4670 / 5670: Computer Vision KavitaBala Source: S. Lazebnik.
CS682, Jana Kosecka Rigid Body Motion and Image Formation Jana Kosecka
Single-view metrology
Prof. Adriana Kovashka University of Pittsburgh October 3, 2016
CS5670: Computer Vision Lecture 9: Cameras Noah Snavely
Jan-Michael Frahm Fall 2016
The Camera : Computational Photography
CSCE 441 Computer Graphics 3-D Viewing
Scene Modeling for a Single View
CS 790: Introduction to Computational Vision
Lecture 13: Cameras and geometry
Lecturer: Dr. A.H. Abdul Hafez
The Camera : Computational Photography
Announcements Midterm out today Project 1 demos.
The Pinhole Camera Model
Announcements Midterm out today Project 1 demos.
Camera model and calibration
Presentation transcript:

Paris town hall

Projective Geometry and Camera Models 09/09/11 Projective Geometry and Camera Models Computer Vision CS 143 Brown James Hays Slides from Derek Hoiem, Alexei Efros, Steve Seitz, and David Forsyth

Administrative Stuff Textbook Matlab Tutorial Office hours James: Monday and Wednesday, 1pm to 2pm Geoff, Monday 7-9pm Paul, Tuesday 7-9pm Sam, Wednesday 7-9pm Evan, Thursday 7-9pm Project 1 is out

Last class: intro Overview of vision, examples of state of art Computer Graphics: Models to Images Comp. Photography: Images to Images Computer Vision: Images to Models

What do you need to make a camera from scratch?

Today’s class Mapping between image and world coordinates Pinhole camera model Projective geometry Vanishing points and lines Projection matrix

Today’s class: Camera and World Geometry How tall is this woman? How high is the camera? What is the camera rotation? What is the focal length of the camera? Which ball is closer?

Image formation Let’s design a camera Idea 1: put a piece of film in front of an object Do we get a reasonable image? Slide source: Seitz

Pinhole camera Idea 2: add a barrier to block off most of the rays Q: How does this transform the image? A: It gets inverted Idea 2: add a barrier to block off most of the rays This reduces blurring The opening known as the aperture Slide source: Seitz

Pinhole camera f c f = focal length c = center of the camera Figure from Forsyth

Camera obscura: the pre-camera Known during classical period in China and Greece (e.g. Mo-Ti, China, 470BC to 390BC) Illustration of Camera Obscura Freestanding camera obscura at UNC Chapel Hill Photo by Seth Ilys

Camera Obscura used for Tracing Lens Based Camera Obscura, 1568

First Photograph Oldest surviving photograph Took 8 hours on pewter plate Photograph of the first photograph Joseph Niepce, 1826 Stored at UT Austin Niepce later teamed up with Daguerre, who eventually created Daguerrotypes

Dimensionality Reduction Machine (3D to 2D) 3D world 2D image Figures © Stephen E. Palmer, 2002

Projection can be tricky… Slide source: Seitz

Projection can be tricky… Slide source: Seitz

Projective Geometry What is lost? Length Who is taller? Which is closer?

Length is not preserved A’ C’ B’ Figure by David Forsyth

Projective Geometry What is lost? Length Angles Parallel? Perpendicular?

Projective Geometry What is preserved? Straight lines are still straight

Vanishing points and lines Parallel lines in the world intersect in the image at a “vanishing point” Go to board, sketch out various properties of vanishing points/lines

Vanishing points and lines Vanishing Line Go to board, sketch out various properties of vanishing points/lines Parallel lines intersect at a point The intersection of red lines and blue lines form a parallelogram Sets of parallel lines on the same plane form a vanishing line Sets of parallel planes form a vanishing line Not all lines that intersect are parallel

Vanishing points and lines Vertical vanishing point (at infinity) Vanishing line Vanishing point Vanishing point Slide from Efros, Photo from Criminisi

Vanishing points and lines Where are the vanishing points? Do buildings on left and buildings on right have the same vanishing line? Which way is the camera tilted? Photo from online Tate collection

Note on estimating vanishing points

Projection: world coordinatesimage coordinates Camera Center (tx, ty, tz) . f Z Y Optical Center (u0, v0) v u

Homogeneous coordinates Conversion Converting to homogeneous coordinates homogeneous image coordinates homogeneous scene coordinates Append coordinate with value 1; proportional coordinate system Converting from homogeneous coordinates

Homogeneous coordinates Invariant to scaling Point in Cartesian is ray in Homogeneous Homogeneous Coordinates Cartesian Coordinates Q: Suppose we have a point in Cartesian coordinates. What is that in homogeneous coordinates? A: a ray

Basic geometry in homogeneous coordinates Line equation: ax + by + c = 0 Append 1 to pixel coordinate to get homogeneous coordinate Line given by cross product of two points Intersection of two lines given by cross product of the lines

Another problem solved by homogeneous coordinates Intersection of parallel lines Cartesian: (Inf, Inf) Homogeneous: (1, 2, 0) Cartesian: (Inf, Inf) Homogeneous: (1, 1, 0) Parallel lines intersect at different infinities

Projection matrix jw kw Ow iw R,T x: Image Coordinates: (u,v,1) Slide Credit: Saverese R,T jw kw Ow iw x: Image Coordinates: (u,v,1) K: Intrinsic Matrix (3x3) R: Rotation (3x3) t: Translation (3x1) X: World Coordinates: (X,Y,Z,1) We can use homogeneous coordinates to write camera matrix in linear form.

Interlude: why does this matter?

Object Recognition (CVPR 2006)

Inserting photographed objects into images (SIGGRAPH 2007) Original Created

Pinhole Camera Model x: Image Coordinates: (u,v,1) K: Intrinsic Matrix (3x3) R: Rotation (3x3) t: Translation (3x1) X: World Coordinates: (X,Y,Z,1)

Projection matrix Intrinsic Assumptions Unit aspect ratio Optical center at (0,0) No skew Extrinsic Assumptions No rotation Camera at (0,0,0) K Work through equations for u and v on board Slide Credit: Saverese

Remove assumption: known optical center Intrinsic Assumptions Unit aspect ratio No skew Extrinsic Assumptions No rotation Camera at (0,0,0)

Remove assumption: square pixels Intrinsic Assumptions No skew Extrinsic Assumptions No rotation Camera at (0,0,0)

Remove assumption: non-skewed pixels Intrinsic Assumptions Extrinsic Assumptions No rotation Camera at (0,0,0) Note: different books use different notation for parameters

Oriented and Translated Camera jw t kw Ow iw

Allow camera translation Intrinsic Assumptions Extrinsic Assumptions No rotation

3D Rotation of Points Slide Credit: Saverese Rotation around the coordinate axes, counter-clockwise: p p’ g y z

Allow camera rotation

Degrees of freedom 5 6 How many known points are needed to estimate this?

Vanishing Point = Projection from Infinity

Orthographic Projection Special case of perspective projection Distance from the COP to the image plane is infinite Also called “parallel projection” What’s the projection matrix? Image World Slide by Steve Seitz

Scaled Orthographic Projection Special case of perspective projection Object dimensions are small compared to distance to camera Also called “weak perspective” What’s the projection matrix? Image World Slide by Steve Seitz

Field of View (Zoom)

Suppose we have two 3D cubes on the ground facing the viewer, one near, one far. What would they look like in perspective? What would they look like in weak perspective? Photo credit: GazetteLive.co.uk

Beyond Pinholes: Radial Distortion Corrected Barrel Distortion Image from Martin Habbecke

Things to remember Vanishing points and vanishing lines Vertical vanishing (at infinity) Vanishing points and vanishing lines Pinhole camera model and camera projection matrix Homogeneous coordinates