Locating and Describing Interest Points Computer Vision CS 543 / ECE 549 University of Illinois Derek Hoiem 03/02/10 Acknowledgment: Many keypoint slides.

Slides:



Advertisements
Similar presentations
Interest points CSE P 576 Ali Farhadi Many slides from Steve Seitz, Larry Zitnick.
Advertisements

The SIFT (Scale Invariant Feature Transform) Detector and Descriptor
Feature Matching and Robust Fitting Computer Vision CS 143, Brown James Hays Acknowledgment: Many slides from Derek Hoiem and Grauman&Leibe 2008 AAAI Tutorial.
Computer Vision CS 143, Brown James Hays
TP14 - Local features: detection and description Computer Vision, FCUP, 2014 Miguel Coimbra Slides by Prof. Kristen Grauman.
Instructor: Mircea Nicolescu Lecture 15 CS 485 / 685 Computer Vision.
Computational Photography
Algorithms and Applications in Computer Vision
Locating and Describing Interest Points
A Study of Approaches for Object Recognition
1 Interest Operator Lectures lecture topics –Interest points 1 (Linda) interest points, descriptors, Harris corners, correlation matching –Interest points.
Distinctive Image Feature from Scale-Invariant KeyPoints
Interest Points and Corners Computer Vision CS 143, Brown James Hays Slides from Rick Szeliski, Svetlana Lazebnik, Derek Hoiem and Grauman&Leibe 2008 AAAI.
Automatic Matching of Multi-View Images
Image Features: Descriptors and matching
SIFT - The Scale Invariant Feature Transform Distinctive image features from scale-invariant keypoints. David G. Lowe, International Journal of Computer.
CS4670: Computer Vision Kavita Bala Lecture 8: Scale invariance.
Distinctive Image Features from Scale-Invariant Keypoints David G. Lowe – IJCV 2004 Brien Flewelling CPSC 643 Presentation 1.
Computational Photography lecture 14 – Matching Keypoints CS 590 Spring 2014 Prof. Alex Berg (Credits to many other folks on individual slides)
Overview Introduction to local features
Interest Points Computational Photography Derek Hoiem, University of Illinois 10/14/10 Galatea of the Spheres Salvador Dali.
Keypoint-based Recognition Computer Vision CS 543 / ECE 549 University of Illinois Derek Hoiem 03/04/10.
Image Stitching Tamara Berg CSE 590 Computational Photography Many slides from Alyosha Efros & Derek Hoiem.
Overview Harris interest points Comparing interest points (SSD, ZNCC, SIFT) Scale & affine invariant interest points Evaluation and comparison of different.
Local invariant features Cordelia Schmid INRIA, Grenoble.
Computer Vision Lecture 4 FEATURE DETECTION. Feature Detection Feature Description Feature Matching Today’s Topics 2.
Photo by Carl Warner. Feature Matching and Robust Fitting Computer Vision James Hays Acknowledgment: Many slides from Derek Hoiem and Grauman&Leibe.
Interest Points Computational Photography Derek Hoiem, University of Illinois 10/24/13 Galatea of the Spheres Salvador Dali.
776 Computer Vision Jan-Michael Frahm Fall SIFT-detector Problem: want to detect features at different scales (sizes) and with different orientations!
CSE 185 Introduction to Computer Vision Local Invariant Features.
CS 1699: Intro to Computer Vision Local Image Features: Extraction and Description Prof. Adriana Kovashka University of Pittsburgh September 17, 2015.
Lecture 7: Features Part 2 CS4670/5670: Computer Vision Noah Snavely.
Local invariant features Cordelia Schmid INRIA, Grenoble.
Harris Corner Detector & Scale Invariant Feature Transform (SIFT)
Overview Introduction to local features Harris interest points + SSD, ZNCC, SIFT Scale & affine invariant interest point detectors Evaluation and comparison.
CSE 185 Introduction to Computer Vision Feature Matching.
Project 3 questions? Interest Points and Instance Recognition Computer Vision CS 143, Brown James Hays 10/21/11 Many slides from Kristen Grauman and.
Local features: detection and description
CS654: Digital Image Analysis
Presented by David Lee 3/20/2006
Interest Points Computational Photography Derek Hoiem, University of Illinois 10/23/12 Galatea of the Spheres Salvador Dali.
776 Computer Vision Jan-Michael Frahm Spring 2012.
CS 2750: Machine Learning Bias-Variance Trade-off (cont’d) + Image Representations Prof. Adriana Kovashka University of Pittsburgh January 20, 2016.
CSE 185 Introduction to Computer Vision Local Invariant Features.
Computer Vision Jia-Bin Huang, Virginia Tech
SIFT Scale-Invariant Feature Transform David Lowe
Interest Points EE/CSE 576 Linda Shapiro.
Lecture 13: Feature Descriptors and Matching
Presented by David Lee 3/20/2006
Lecture 07 13/12/2011 Shai Avidan הבהרה: החומר המחייב הוא החומר הנלמד בכיתה ולא זה המופיע / לא מופיע במצגת.
Local features: main components
Project 1: hybrid images
Motion illusion, rotating snakes
Corners and interest points
TP12 - Local features: detection and description
Source: D. Lowe, L. Fei-Fei Recap: edge detection Source: D. Lowe, L. Fei-Fei.
Scale and interest point descriptors
Local features: detection and description May 11th, 2017
Feature description and matching
Photo by Carl Warner.
Brief Review of Recognition + Context
The SIFT (Scale Invariant Feature Transform) Detector and Descriptor
SIFT keypoint detection
CSE 185 Introduction to Computer Vision
Lecture VI: Corner and Blob Detection
Feature descriptors and matching
Lecture 5: Feature invariance
Presentation transcript:

Locating and Describing Interest Points Computer Vision CS 543 / ECE 549 University of Illinois Derek Hoiem 03/02/10 Acknowledgment: Many keypoint slides from Grauman&Leibe 2008 AAAI Tutorial

What is “object recognition”?

1. Identify a Specific Instance General objects – Challenges: rotation, scale, occlusion, localization – Approaches Geometric configurations of keypoints (Lowe 2004) – Works well for planar, textured objects

1. Identify a Specific Instance Faces – Typical scenario: few examples per face, identify or verify test example – What’s hard: changes in expression, lighting, age, occlusion, viewpoint – Basic approaches (all nearest neighbor) 1.Project into a new subspace (or kernel space) (e.g., “Eigenfaces”=PCA) 2.Measure face features 3.Make 3d face model, compare shape+appearance (e.g., AAM)

2. Detect Instance of a Category Much harder than specific instance recognition Challenges – Everything in instance recognition – Intraclass variation – Representation becomes crucial

2. Detect Instance of a Category Template or sliding window Works well when – Object fits well into rectangular window – Interior features are discriminative Schneiderman Kanade 2000

2. Detect Instance of a Category Parts-based Fischler and Elschlager 1973 Felzenszwalb et al. 2008

3. Assign a label to a pixel or region Stuff – Materials, object regions, textures, etc. – Approaches Label patches + CRF Segmentation + Label Regions

Next two lectures Object instance recognition – Interest points (today) Detecting Representing Simple matching – Recognizing objects with interest points (Thurs) Geometric verification – RANSAC + Hough voting Efficient matching

General Process of Object Recognition Specify Object Model Generate Hypotheses Score Hypotheses Resolution

General Process of Object Recognition Example: Template Matching Specify Object Model Generate Hypotheses Score Hypotheses Resolution Intensity Template, at x-y Scanning window Normalized X-Corr Threshold + Non- max suppression

General Process of Object Recognition Example: Keypoint-based Instance Recognition Specify Object Model Generate Hypotheses Score Hypotheses Resolution B1B1 B2B2 B3B3 A1A1 A2A2 A3A3 Affine Parameters Choose hypothesis with max score above threshold # Inliers Affine-variant point locations

General Process of Object Recognition Example: Keypoint-based Instance Recognition Specify Object Model Generate Hypotheses Score Hypotheses Resolution B1B1 B2B2 B3B3 A1A1 A2A2 A3A3 Today’s Class

Overview of Keypoint Matching K. Grauman, B. Leibe B1B1 B2B2 B3B3 A1A1 A2A2 A3A3 1. Find a set of distinctive key- points 3. Extract and normalize the region content 2. Define a region around each keypoint 4. Compute a local descriptor from the normalized region 5. Match local descriptors

Main challenges Change in position and scale Change in viewpoint Occlusion Articulation

Goals for Keypoints Detect points that are repeatable and distinctive

Key trade-offs More Points More Repeatable B1B1 B2B2 B3B3 A1A1 A2A2 A3A3 Localization More Robust More Selective Description Robust to occlusion Works with less texture Robust detection Precise localization Deal with expected variations Maximize correct matches Minimize wrong matches

Keypoint localization More Points More Repeatable Key Trade-off Goals: –Repeatable detection –Precise localization –Interesting content

Keypoint Localization Goals: –Repeatable detection –Precise localization –Interesting content K. Grauman, B. Leibe

Keypoint Localization Goals: –Repeatable detection –Precise localization –Interesting content  Look for two-dimensional signal changes K. Grauman, B. Leibe

Choosing interest points If you wanted to meet a friend would you say a)“Let’s meet on campus.” b)“Let’s meet on Green street.” c)“Let’s meet at Green and Wright.” – Corner detection Or if you were in a secluded area: a)“Let’s meet in the Plains of Akbar.” b)“Let’s meet on the side of Mt. Doom.” c)“Let’s meet on top of Mt. Doom.” – Blob (valley/peak) detection

Choosing interest points Corners – “Let’s meet at Green and Wright.” Peaks/Valleys – “Let’s meet on top of Mt. Doom.”

Many Existing Detectors Available K. Grauman, B. Leibe Hessian & Harris [Beaudet ‘78], [Harris ‘88] Laplacian, DoG [Lindeberg ‘98], [Lowe 1999] Harris-/Hessian-Laplace [Mikolajczyk & Schmid ‘01] Harris-/Hessian-Affine [Mikolajczyk & Schmid ‘04] EBR and IBR [Tuytelaars & Van Gool ‘04] MSER [Matas ‘02] Salient Regions [Kadir & Brady ‘01] Others…

Hessian Detector [ Beaudet78] Hessian determinant K. Grauman, B. Leibe I xx I yy I xy Intuition: Search for strong derivatives in two orthogonal directions

Hessian Detector [ Beaudet78] Hessian determinant K. Grauman, B. Leibe I xx I yy I xy In Matlab:

Hessian Detector – Responses [ Beaudet78] Effect: Responses mainly on corners and strongly textured areas.

Hessian Detector – Responses [ Beaudet78]

Harris Detector [ Harris88 ] Second moment matrix (autocorrelation matrix) K. Grauman, B. Leibe Intuition: Search for local neighborhoods where the image content has two main directions (eigenvectors).

Harris Detector [ Harris88 ] Second moment matrix (autocorrelation matrix) K. Grauman, B. Leibe 1.Image derivatives g x (  D ), g y (  D ), IxIx IyIy

Harris Detector [ Harris88 ] Second moment matrix (autocorrelation matrix) 30K. Grauman, B. Leibe 1.Image derivatives g x (  D ), g y (  D ), IxIx IyIy Square of derivatives Ix2Ix2 Iy2Iy2 IxIyIxIy

Harris Detector [ Harris88 ] Second moment matrix (autocorrelation matrix) 1.Image derivatives g x (  D ), g y (  D ), 2. Square of derivatives IyIy 1. Image derivatives 2. Square of derivatives 3. Gaussian filter g(  I ) IxIx IyIy Ix2Ix2 Iy2Iy2 IxIyIxIy g(I x 2 )g(I y 2 )g(I x I y ) 31

Harris Detector [ Harris88 ] Second moment matrix (autocorrelation matrix) Image derivatives 2. Square of derivatives 3. Gaussian filter g(  I ) IxIx IyIy Ix2Ix2 Iy2Iy2 IxIyIxIy g(I x 2 )g(I y 2 ) g(I x I y ) 4. Cornerness function – both eigenvalues are strong har 5. Non-maxima suppression g(I x I y )

Harris Detector: Mathematics 1.Want large eigenvalues, and small ratio 2.We know 3.Leads to (k :empirical constant, k = )

Harris Detector – Responses [ Harris88 ] Effect: A very precise corner detector.

Harris Detector – Responses [ Harris88 ]

So far: can localize in x-y, but not scale

Automatic Scale Selection K. Grauman, B. Leibe How to find corresponding patch sizes?

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

Automatic Scale Selection Function responses for increasing scale (scale signature) K. Grauman, B. Leibe

What Is A Useful Signature Function? Laplacian-of-Gaussian = “blob” detector K. Grauman, B. Leibe

Laplacian-of-Gaussian (LoG) Local maxima in scale space of Laplacian-of- Gaussian K. Grauman, B. Leibe       List of (x, y, s)

Results: Laplacian-of-Gaussian K. Grauman, B. Leibe

Difference-of-Gaussian (DoG) Difference of Gaussians as approximation of the Laplacian-of-Gaussian K. Grauman, B. Leibe - =

DoG – Efficient Computation Computation in Gaussian scale pyramid K. Grauman, B. Leibe  Original image Sampling with step    =2   

Results: Lowe’s DoG K. Grauman, B. Leibe

T. Tuytelaars, B. Leibe Orientation Normalization Compute orientation histogram Select dominant orientation Normalize: rotate to fixed orientation 0 2  [Lowe, SIFT, 1999]

Harris-Laplace [Mikolajczyk ‘01] 1.Initialization: Multiscale Harris corner detection     Computing Harris functionDetecting local maxima

Harris-Laplace [Mikolajczyk ‘01] 1.Initialization: Multiscale Harris corner detection 2.Scale selection based on Laplacian (same procedure with Hessian  Hessian-Laplace) K. Grauman, B. Leibe Harris points Harris-Laplace points

Maximally Stable Extremal Regions [Matas ‘02] Based on Watershed segmentation algorithm Select regions that stay stable over a large parameter range K. Grauman, B. Leibe

Example Results: MSER 54K. Grauman, B. Leibe

Comparison LoG Hessian MSER Harris

Available at a web site near you… For most local feature detectors, executables are available online: – – – K. Grauman, B. Leibe

Local Descriptors The ideal descriptor should be – Robust – Distinctive – Compact – Efficient Most available descriptors focus on edge/gradient information – Capture texture information – Color rarely used K. Grauman, B. Leibe

Local Descriptors: SIFT Descriptor [Lowe, ICCV 1999] Histogram of oriented gradients Captures important texture information Robust to small translations / affine deformations K. Grauman, B. Leibe

Details of Lowe’s SIFT algorithm Run DoG detector – Find maxima in location/scale space – Remove edge points Find all major orientations – Bin orientations into 36 bin histogram Weight by gradient magnitude Weight by distance to center (Gaussian-weighted mean) – Return orientations within 0.8 of peak Use parabola for better orientation fit For each (x,y,scale,orientation), create descriptor: – Sample 16x16 gradient mag. and rel. orientation – Bin 4x4 samples into 4x4 histograms – Threshold values to max of 0.2, divide by L2 norm – Final descriptor: 4x4x8 normalized histograms Lowe IJCV 2004

Matching SIFT Descriptors Nearest neighbor (Euclidean distance) Threshold ratio of nearest to 2 nd nearest descriptor Lowe IJCV 2004

SIFT Repeatability Lowe IJCV 2004

SIFT Repeatability

Lowe IJCV 2004

SIFT Repeatability Lowe IJCV 2004

Local Descriptors: SURF K. Grauman, B. Leibe Fast approximation of SIFT idea  Efficient computation by 2D box filters & integral images  6 times faster than SIFT  Equivalent quality for object identification [Bay, ECCV’06], [Cornelis, CVGPU’08] GPU implementation available  Feature 200Hz (detector + descriptor, 640×480 img) 

Local Descriptors: Shape Context Count the number of points inside each bin, e.g.: Count = 4 Count = Log-polar binning: more precision for nearby points, more flexibility for farther points. Belongie & Malik, ICCV 2001 K. Grauman, B. Leibe

Local Descriptors: Geometric Blur Example descriptor ~ Compute edges at four orientations Extract a patch in each channel Apply spatially varying blur and sub-sample (Idealized signal) Berg & Malik, CVPR 2001 K. Grauman, B. Leibe

Choosing a detector What do you want it for? – Precise localization in x-y: Harris – Good localization in scale: Difference of Gaussian – Flexible region shape: MSER Best choice often application dependent – Harris-/Hessian-Laplace/DoG work well for many natural categories – MSER works well for buildings and printed things Why choose? – Get more points with more detectors There have been extensive evaluations/comparisons – [Mikolajczyk et al., IJCV’05, PAMI’05] – All detectors/descriptors shown here work well

Comparison of Keypoint Detectors Tuytelaars Mikolajczyk 2008

Choosing a descriptor Again, need not stick to one For object instance recognition or stitching, SIFT or variant is a good choice

Things to remember Keypoint detection: repeatable and distinctive – Corners, blobs, stable regions – Harris, DoG Descriptors: robust and selective – spatial histograms of orientation – SIFT

Next time Recognizing objects using keypoints