Single-view Metrology and Cameras

Similar documents
Unit 1: Image Formation

Projection. Readings. Szeliski 2.1. Wednesday, October 23, 13

How do we see the world?

The Camera : Computational Photography Alexei Efros, CMU, Fall 2008

Projection. Projection. Image formation. Müller-Lyer Illusion. Readings. Readings. Let s design a camera. Szeliski 2.1. Szeliski 2.

IMAGE FORMATION. Light source properties. Sensor characteristics Surface. Surface reflectance properties. Optics

Two strategies for realistic rendering capture real world data synthesize from bottom up

The Camera : Computational Photography Alexei Efros, CMU, Fall 2005

Building a Real Camera. Slides Credit: Svetlana Lazebnik

Projection. Announcements. Müller-Lyer Illusion. Image formation. Readings Nalwa 2.1

Building a Real Camera

Cameras. CSE 455, Winter 2010 January 25, 2010

CS6670: Computer Vision

CS6670: Computer Vision

Lecture 02 Image Formation 1

Overview. Pinhole camera model Projective geometry Vanishing points and lines Projection matrix Cameras with Lenses Color Digital image

Computer Vision. The Pinhole Camera Model

CSE 473/573 Computer Vision and Image Processing (CVIP)

Image Formation. Dr. Gerhard Roth. COMP 4102A Winter 2015 Version 3

Cameras. Digital Visual Effects, Spring 2008 Yung-Yu Chuang 2008/2/26. with slides by Fredo Durand, Brian Curless, Steve Seitz and Alexei Efros

Cameras. Shrinking the aperture. Camera trial #1. Pinhole camera. Digital Visual Effects Yung-Yu Chuang. Put a piece of film in front of an object.

Image formation - Cameras. Grading & Project. About the course. Tentative Schedule. Course Content. Students introduction

6.098 Digital and Computational Photography Advanced Computational Photography. Bill Freeman Frédo Durand MIT - EECS

Image Processing & Projective geometry

LENSES. INEL 6088 Computer Vision

Dr F. Cuzzolin 1. September 29, 2015

CSE 527: Introduction to Computer Vision

Image Formation III Chapter 1 (Forsyth&Ponce) Cameras Lenses & Sensors

Midterm Examination CS 534: Computational Photography

Modeling and Synthesis of Aperture Effects in Cameras

Cameras. Outline. Pinhole camera. Camera trial #1. Pinhole camera Film camera Digital camera Video camera

6.A44 Computational Photography

MEM: Intro to Robotics. Assignment 3I. Due: Wednesday 10/15 11:59 EST

Computational Photography and Video. Prof. Marc Pollefeys

Dynamically Reparameterized Light Fields & Fourier Slice Photography. Oliver Barth, 2009 Max Planck Institute Saarbrücken

Using Optics to Optimize Your Machine Vision Application

Cameras and Sensors. Today. Today. It receives light from all directions. BIL721: Computational Photography! Spring 2015, Lecture 2!

Cameras. Steve Rotenberg CSE168: Rendering Algorithms UCSD, Spring 2017

Dappled Photography: Mask Enhanced Cameras for Heterodyned Light Fields and Coded Aperture Refocusing

Physics 3340 Spring Fourier Optics

Reading. Angel. Chapter 5. Optional

OPTICS I LENSES AND IMAGES

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

To Do. Advanced Computer Graphics. Outline. Computational Imaging. How do we see the world? Pinhole camera

Phys 531 Lecture 9 30 September 2004 Ray Optics II. + 1 s i. = 1 f

Lecture 2 Camera Models

Announcement A total of 5 (five) late days are allowed for projects. Office hours

Aperture & ƒ/stop Worksheet

Aperture and Digi scoping. Thoughts on the value of the aperture of a scope digital camera combination.

Basic principles of photography. David Capel 346B IST

Douglas Photo. Version for iosand Android

Types of lenses. Shown below are various types of lenses, both converging and diverging.

Understanding Focal Length

Prof. Feng Liu. Spring /05/2017

Aberrations, Camera, Eye

Lecture 9. Lecture 9. t (min)

Homographies and Mosaics

Acquisition. Some slides from: Yung-Yu Chuang (DigiVfx) Jan Neumann, Pat Hanrahan, Alexei Efros

Name: Date: Math in Special Effects: Try Other Challenges. Student Handout

Image Formation and Capture

Homographies and Mosaics

Lecture 22: Cameras & Lenses III. Computer Graphics and Imaging UC Berkeley CS184/284A, Spring 2017

Physics 1230: Light and Color. Guest Lecture, Jack again. Lecture 23: More about cameras

Lens Aperture. South Pasadena High School Final Exam Study Guide- 1 st Semester Photo ½. Study Guide Topics that will be on the Final Exam

3D Viewing. Introduction to Computer Graphics Torsten Möller / Manfred Klaffenböck. Machiraju/Zhang/Möller

Determining MTF with a Slant Edge Target ABSTRACT AND INTRODUCTION

Computational Approaches to Cameras

Name: Lab Partner: Section:

Image stitching. Image stitching. Video summarization. Applications of image stitching. Stitching = alignment + blending. geometrical registration

Image Formation and Capture. Acknowledgment: some figures by B. Curless, E. Hecht, W.J. Smith, B.K.P. Horn, and A. Theuwissen

Creating a Panorama Photograph Using Photoshop Elements

Physics 1230 Homework 8 Due Friday June 24, 2016

Section 3. Imaging With A Thin Lens

Cameras. Outline. Pinhole camera. Camera trial #1. Pinhole camera Film camera Digital camera Video camera High dynamic range imaging

VC 14/15 TP2 Image Formation

1 Laboratory 7: Fourier Optics

Image Formation. Dr. Gerhard Roth. COMP 4102A Winter 2014 Version 1

Sensors and Sensing Cameras and Camera Calibration

Topic 6 - Optics Depth of Field and Circle Of Confusion

PHY 1160C Homework Chapter 26: Optical Instruments Ch 26: 2, 3, 5, 9, 13, 15, 20, 25, 27

Introduction to camera usage. The universal manual controls of most cameras

Overview. Image formation - 1

25 Questions. All are multiple choice questions. 4 will require an additional written response explaining your answer.

Lecture 18: Light field cameras. (plenoptic cameras) Visual Computing Systems CMU , Fall 2013

The Formation of an Aerial Image, part 3

CAMERA BASICS. Stops of light

Be aware that there is no universal notation for the various quantities.

Image Formation. World Optics Sensor Signal. Computer Vision. Introduction to. Light (Energy) Source. Surface Imaging Plane. Pinhole Lens.

Image Formation: Camera Model

Computational Camera & Photography: Coded Imaging

VC 11/12 T2 Image Formation

Computational Cameras. Rahul Raguram COMP

MIT CSAIL Advances in Computer Vision Fall Problem Set 6: Anaglyph Camera Obscura

Lenses. Images. Difference between Real and Virtual Images

Digital Image Processing COSC 6380/4393

DSLR Cameras have a wide variety of lenses that can be used.

Opto Engineering S.r.l.

[ Summary. 3i = 1* 6i = 4J;

Fundamental Paraxial Equation for Thin Lenses

CS354 Computer Graphics Viewing and Projections

Transcription:

Single-view Metrology and Cameras 10/10/17 Computational Photography Derek Hoiem, University of Illinois

Project 2 Results Incomplete list of great project pages Haohang Huang: Best presented project; nice iterative results and demonstration, animations for hole filling Xiaotian Le: Runner Up Project: Cool Sliding Window to demonstrate difference in textures (most liked) Xiaoyan Wang: Runner Up Project: Cool QR Code Texture Transfer and Toast results Kartik Agarwal: Overall nice project Ho Yin Au: Nice seam finding results Yuanzhe Rijn Bian: Nice Einstein Toast Result Yundi Fei: Nice seam finding results Zih Siou Hung: Nice Van Gogh texture transfer onto a cat Brendan Wilson (synthesized pattern): Very unique texture patterns that were explored Zexuan Zhong: Best hole filling exploration

Texture synthesis Brendan Wilson

Texture synthesis Brendan Wilson

Texture transfer Zih Siou Hung

Hole filling Zexuan Zhong

Review: Pinhole Camera Optical Center (u. 0, v 0 ) f Z Y.. P X Y Z. u v u p v Camera Center (t x, t y, t z )

Review: Projection Matrix 1 1 0 0 0 1 33 32 31 23 22 21 13 12 11 0 0 Z Y X t r r r t r r r t r r r v f u s f v u w z y x X t x K R O w i w k w j w t R

Take-home questions from last week Suppose the camera axis is in the direction of (x=0, y=0, z=1) in its own coordinate system. What is the camera axis in world coordinates given the extrinsic parameters R, t Suppose a camera at height y=h (x=0,z=0) observes a point at (u,v) known to be on the ground (y=0). Assume R is identity. What is the 3D position of the point in terms of f, u 0, v 0?

Slide from Efros, Photo from Criminisi Review: Vanishing Points Vertical vanishing point (at infinity) Vanishing line Vanishing point Vanishing point

Perspective and weak perspective Photo credit: GazetteLive.co.uk

This class How can we calibrate the camera? How can we measure the size of objects in the world from an image? What about other camera properties: focal length, field of view, depth of field, aperture, f-number? How to do focus stacking to get a sharp picture of a nearby object How the vertigo effect works

How to calibrate the camera? 1 * * * * * * * * * * * * Z Y X w wv wu X t x K R

Calibrating the Camera Method 1: Use an object (calibration grid) with known geometry Correspond image points to 3d points Get least squares solution (or non-linear solution) wu wv w m m m 11 21 31 m m m 12 22 32 m m m 13 23 33 m m m 14 24 34 X Y Z 1

Calibrating the Camera Method 2: Use vanishing points Find vanishing points corresponding to orthogonal directions Vanishing line Vertical vanishing point (at infinity) Vanishing point Vanishing point

Take-home question (for later) Suppose you have estimated finite three vanishing points corresponding to orthogonal directions: 1) How to solve for intrinsic matrix? (assume K has three parameters) The transpose of the rotation matrix is its inverse Use the fact that the 3D directions are orthogonal 2) How to recover the rotation matrix that is aligned with the 3D axes defined by these points? In homogeneous coordinates, 3d point at infinity is (X, Y, Z, 0) VP y VP x. VP z Photo from online Tate collection

How can we measure the size of 3D objects from an image? Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Perspective cues Slide by Steve Seitz

Ames Room

Comparing heights Slide by Steve Seitz Vanishing Point

Measuring height Slide by Steve Seitz 5 4 3 2 5.4 Camera height 3.3 2.8 1

Two views of a scene Parallel to ground camera center Image horizon image plane ground camera looks down slight foreshortening due to camera angle

Which is higher the camera or the parachute?

Measuring height without a giant ruler Slide by Steve Seitz C Z ground plane Compute Z from image measurements Need a reference object

The cross ratio A Projective Invariant Something that does not change under projective transformations (including perspective projection) P 1 P 2 P 3 P 4 1 4 2 3 2 4 1 3 P P P P P P P P 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 1 i i i i Z Y X P 3 4 2 1 2 4 3 1 P P P P P P P P Slide by Steve Seitz

v Z r t b t v r b r v t b Z Z image cross ratio Measuring height B (bottom of object) T (top of object) R (reference point) ground plane H C T R B R T B scene cross ratio 1 Z Y X P 1 y x p scene points represented as image points as R H R H R Slide by Steve Seitz

Measuring height v z r Slide by Steve Seitz vanishing line (horizon) v x v t 0 H t R H v y b 0 t b r b v v Z Z r t image cross ratio b

Measuring height v z r Slide by Steve Seitz vanishing line (horizon) t 0 v x t 0 v v y m 0 t 1 b 0 b 1 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 b

Take-home question Assume that the man is 6 ft tall What is the height of the front of the building? What is the height of the camera?

Beyond the pinhole: What about focus, aperture, DOF, FOV, etc? Optical Center (u. 0, v 0 ) f Z Y.. P X Y Z. u v u p v Camera Center (t x, t y, t z )

Adding a lens circle of confusion A lens focuses light onto the film There is a specific distance at which objects are in focus other points project to a circle of confusion in the image Changing the shape of the lens changes this distance

Focal length, aperture, depth of field F optical center (Center Of Projection) focal point A lens focuses parallel rays onto a single focal point focal point at a distance f beyond the plane of the lens Aperture of diameter D restricts the range of rays Slide source: Seitz

The eye The human eye is a camera Iris - colored annulus with radial muscles Pupil - the hole (aperture) whose size is controlled by the iris

Focus with lenses Distance to object Distance to sensor Lens focal length Equation for objects in focus Source: http://en.wikipedia.org/wiki/file:lens3.svg

The aperture and depth of field Slide source: Seitz f / 5.6 f / 32 Changing the aperture size or focusing distance affects depth of field f-number (f/#) =focal_length / aperture_diameter (e.g., f/16 means that the focal length is 16 times the diameter) When you change the f-number, you are changing the aperture Flower images from Wikipedia http://en.wikipedia.org/wiki/depth_of_field

Large aperture = small DOF Small aperture = large DOF Varying the aperture Slide from Efros

Shrinking the aperture Why not make the aperture as small as possible? Less light gets through Diffraction effects Slide by Steve Seitz

Shrinking the aperture Slide by Steve Seitz

The Photographer s Great Compromise What we want More spatial resolution Broader field of view More depth of field How we get it Increase focal length Decrease focal length Decrease aperture Increase aperture Cost Light, FOV DOF Light DOF More temporal resolution Shorten exposure Lengthen exposure Light Temporal Res More light

Difficulty in macro (close-up) photography For close objects, we have a small relative DOF Can only shrink aperture so far How to get both bugs in focus?

Solution: Focus stacking 1. Take pictures with varying focal length Example from http://www.wonderfulphotos.com/articles/macro/focus_stacking/

Solution: Focus stacking 1. Take pictures with varying focal length 2. Combine

Focus stacking http://www.wonderfulphotos.com/articles/macro/focus_stacking/

Focus stacking How to combine? Web answer: With software (Photoshop, CombineZM) How to do it automatically?

Focus stacking How to combine? 1. Align images (e.g., using corresponding points) 2. Two ideas a) Mask regions by hand and combine with pyramid blend b) Gradient domain fusion (mixed gradient) without masking Automatic solution would make an interesting final project Recommended Reading: http://www.digital-photographyschool.com/an-introduction-to-focusstacking http://www.zen20934.zen.co.uk/photograph y/workflow.htm#focus%20stacking

Relation between field of view and focal length Field of view (angle width) fov 2tan 1 d 2 f Film/Sensor Width Focal length

Dolly Zoom or Vertigo Effect http://www.youtube.com/watch?v=nb4bikrnzmk How is this done? Zoom in while moving away http://en.wikipedia.org/wiki/focal_length

Dolly zoom (or Vertigo effect ) Field of view (angle width) fov 2 tan 1 d 2 f Film/Sensor Width Focal length 2 tan 2 fov width distance width of object Distance between object and camera

Things to remember Can calibrate using grid or VP Can measure relative sizes using VP 5 4 3 2 1 Effects of focal length, aperture + tricks

Next class Go over take-home questions from today Single-view 3D Reconstruction