More Mosaic Madness 15-463: Computational Photography Alexei Efros, CMU, Fall 2006 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen from.

Slides:



Advertisements
Similar presentations
Computer Vision, Robert Pless
Advertisements

The Camera : Computational Photography Alexei Efros, CMU, Fall 2006.
RANSAC and mosaic wrap-up cs129: Computational Photography James Hays, Brown, Fall 2012 © Jeffrey Martin (jeffrey-martin.com) most slides from Steve Seitz,
CS 691 Computational Photography Instructor: Gianfranco Doretto 3D to 2D Projections.
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.
CSCE 641 Computer Graphics: Image Mosaicing Jinxiang Chai.
Mosaics con’t CSE 455, Winter 2010 February 10, 2010.
Image Stitching.
Computational Photography: Image Mosaicing Jinxiang Chai.
Announcements Project 2 Out today Sign up for a panorama kit ASAP! –best slots (weekend) go quickly...
Announcements Project 1 artifact voting ( announce later today) Project 2 out today (help session at end of class) IMPORTANT: choose Proj 2 partner.
Announcements. Projection Today’s Readings Nalwa 2.1.
Homographies and Mosaics : Computational Photography Alexei Efros, CMU, Fall 2005 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen.
Lecture 5: Projection CS6670: Computer Vision Noah Snavely.
1Jana Kosecka, CS 223b Cylindrical panoramas Cylindrical panoramas.
Lecture 7: Image Alignment and Panoramas CS6670: Computer Vision Noah Snavely What’s inside your fridge?
Lecture 6: Image transformations and alignment CS6670: Computer Vision Noah Snavely.
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.
Lecture 13: Projection, Part 2
Announcements Project 2 out today panorama signup help session at end of class Today mosaic recap blending.
Announcements Project 1 artifact voting Project 2 out today panorama signup help session at end of class Guest lectures next week: Li Zhang, Jiwon Kim.
1Jana Kosecka, CS 223b Cylindrical panoramas Cylindrical panoramas with some slides from R. Szeliski, S. Seitz, D. Lowe, A. Efros,
Lecture 6: Image Warping and Projection CS6670: Computer Vision Noah Snavely.
CSCE 641 Computer Graphics: Image Mosaicing Jinxiang Chai.
More Mosaic Madness : Computational Photography Alexei Efros, CMU, Fall 2005 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen from.
Panoramas and Calibration : Rendering and Image Processing Alexei Efros …with a lot of slides stolen from Steve Seitz and Rick Szeliski.
Image Warping and Mosacing : Rendering and Image Processing Alexei Efros …with a lot of slides stolen from Steve Seitz and Rick Szeliski.
Announcements Project 1 Grading session this afternoon Artifacts due Friday (voting TBA) Project 2 out (online) Signup for panorama kits ASAP (weekend.
The Camera : Computational Photography Alexei Efros, CMU, Fall 2008.
Announcements Project 1 artifact voting Project 2 out today (help session at end of class)
Announcements Midterm due Friday, beginning of lecture Guest lecture on Friday: Antonio Criminisi, Microsoft Research.
Mosaics CSE 455, Winter 2010 February 8, 2010 Neel Joshi, CSE 455, Winter Announcements  The Midterm went out Friday  See to the class.
Image Stitching Ali Farhadi CSE 455
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
776 Computer Vision Jan-Michael Frahm Fall Camera.
Course 12 Calibration. 1.Introduction In theoretic discussions, we have assumed: Camera is located at the origin of coordinate system of scene.
Recap from Wednesday Two strategies for realistic rendering capture real world data synthesize from bottom up Both have existed for 500 years. Both are.
Camera calibration Digital Visual Effects Yung-Yu Chuang with slides by Richard Szeliski, Steve Seitz,, Fred Pighin and Marc Pollefyes.
Mosaics Today’s Readings Szeliski, Ch 5.1, 8.1 StreetView.
Image stitching Digital Visual Effects Yung-Yu Chuang with slides by Richard Szeliski, Steve Seitz, Matthew Brown and Vaclav Hlavac.
Metrology 1.Perspective distortion. 2.Depth is lost.
CS4670 / 5670: Computer Vision KavitaBala Lecture 17: Panoramas.
CS-498 Computer Vision Week 7, Day 2 Camera Parameters Intrinsic Calibration  Linear  Radial Distortion (Extrinsic Calibration?) 1.
Feature Matching. Feature Space Outlier Rejection.
Mosaics part 3 CSE 455, Winter 2010 February 12, 2010.
Making Panoramas. Input: Output: … Input:  A set of images taken from the same optical center.  For this project, the images will also have the same.
Mosaics Today’s Readings Szeliski and Shum paper (sections 1 and 2, skim the rest) –
Lecture 14: Projection CS4670 / 5670: Computer Vision Noah Snavely “The School of Athens,” Raphael.
Image Stitching Computer Vision CS 691E Some slides from Richard Szeliski.
Homographies and Mosaics : Computational Photography Alexei Efros, CMU, Fall 2006 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen.
Prof. Adriana Kovashka University of Pittsburgh October 3, 2016
CS4670 / 5670: Computer Vision Kavita Bala Lecture 20: Panoramas.
More Mosaic Madness © Jeffrey Martin (jeffrey-martin.com)
The Camera : Computational Photography
RANSAC and mosaic wrap-up
More Mosaic Madness : Computational Photography
Image Stitching Slides from Rick Szeliski, Steve Seitz, Derek Hoiem, Ira Kemelmacher, Ali Farhadi.
Overview Pin-hole model From 3D to 2D Camera projection
More Mosaic Madness © Jeffrey Martin (jeffrey-martin.com)
Idea: projecting images onto a common plane
Announcements Project 2 out today (help session at end of class)
More Mosaic Madness : Computational Photography
The Camera : Computational Photography
Image Stitching Computer Vision CS 678
More Mosaic Madness © Jeffrey Martin (jeffrey-martin.com)
Announcements Project 1 Project 2 Vote for your favorite artifacts!
Announcements Project 1 artifact voting Project 2 out today
Image Stitching Linda Shapiro ECE/CSE 576.
Image Stitching Linda Shapiro ECE P 596.
Presentation transcript:

More Mosaic Madness : Computational Photography Alexei Efros, CMU, Fall 2006 © Jeffrey Martin (jeffrey-martin.com) with a lot of slides stolen from Steve Seitz and Rick Szeliski

Homography A: Projective – mapping between any two PPs with the same center of projection rectangle should map to arbitrary quadrilateral parallel lines aren’t but must preserve straight lines same as: project, rotate, reproject called Homography PP2 PP1 Hpp’ To apply a homography H Compute p’ = Hp (regular matrix multiply) Convert p’ from homogeneous to image coordinates

Rotational Mosaics Can we say something more about rotational mosaics? i.e. can we further constrain our H?

3D → 2D Perspective Projection u (X c,Y c,Z c ) ucuc f K

3D Rotation Model Projection equations 1.Project from image to 3D ray (x 0,y 0,z 0 ) = (u 0 -u c,v 0 -v c,f) 2.Rotate the ray by camera motion (x 1,y 1,z 1 ) = R 01 (x 0,y 0,z 0 ) 3.Project back into new (source) image (u 1,v 1 )= (fx 1 /z 1 +u c,fy 1 /z 1 +v c ) Therefore: Our homography has only 3,4 or 5 DOF, depending if focal length is known, same, or different. This makes image registration much better behaved (u,v,f)(x,y,z) f (u,v,f) R

Pairwise alignment Procrustes Algorithm [Golub & VanLoan] Given two sets of matching points, compute R p i ’ = R p i with 3D rays p i = N(x i,y i,z i ) = N(u i -u c,v i -v c,f) A = Σ i p i p i ’ T = Σ i p i p i T R T = U S V T = (U S U T ) R T V T = U T R T R = V U T

Rotation about vertical axis What if our camera rotates on a tripod? What’s the structure of H?

mosaic PP Do we have to project onto a plane?

Full Panoramas What if you want a 360  field of view? mosaic Projection Cylinder

Map 3D point (X,Y,Z) onto cylinder Cylindrical projection X Y Z unit cylinder unwrapped cylinder Convert to cylindrical coordinates cylindrical image Convert to cylindrical image coordinates

Cylindrical Projection Y X

Inverse Cylindrical projection X Y Z (X,Y,Z)(X,Y,Z) (sin ,h,cos  )

Cylindrical panoramas Steps Reproject each image onto a cylinder Blend Output the resulting mosaic

Cylindrical image stitching What if you don’t know the camera rotation? Solve for the camera rotations –Note that a rotation of the camera is a translation of the cylinder!

Assembling the panorama Stitch pairs together, blend, then crop

Problem: Drift Vertical Error accumulation small (vertical) errors accumulate over time apply correction so that sum = 0 (for 360° pan.) Horizontal Error accumulation can reuse first/last image to find the right panorama radius

Full-view (360°) panoramas

Spherical projection unwrapped sphere Convert to spherical coordinates spherical image Convert to spherical image coordinates X Y Z Map 3D point (X,Y,Z) onto sphere 

Spherical Projection Y X

Inverse Spherical projection X Y Z (x,y,z) (sinθcosφ,cosθcosφ,sinφ) cos φ φ cos θ cos φ sin φ

3D rotation Rotate image before placing on unrolled sphere X Y Z (x,y,z) (sinθcosφ,cosθcosφ,sinφ) cos φ φ cos θ cos φ sin φ _ p = R p

Full-view Panorama

Polar Projection Extreme “bending” in ultra-wide fields of view

Other projections are possible You can stitch on the plane and then warp the resulting panorama What’s the limitation here? Or, you can use these as stitching surfaces But there is a catch…

f = 180 (pixels) Cylindrical reprojection f = 380f = 280 Image 384x300 top-down view Focal length – the dirty secret…

What’s your focal length, buddy? Focal length is (highly!) camera dependant Can get a rough estimate by measuring FOV: Can use the EXIF data tag (might not give the right thing) Can use several images together and try to find f that would make them match Can use a known 3D object and its projection to solve for f Etc. There are other camera parameters too: Optical center, non-square pixels, lens distortion, etc.

Distortion Radial distortion of the image Caused by imperfect lenses Deviations are most noticeable for rays that pass through the edge of the lens No distortionPin cushionBarrel

Radial distortion Correct for “bending” in wide field of view lenses Use this instead of normal projection