Keypoints&Descriptors
Keypoints&Descriptors
Descriptors
Srikumar
Ramalingam
Problem
Statement
Keypoints and Descriptors
Scale Space
and Image
Kernels
Corner
Detection
Srikumar Ramalingam
SIFT
School of Computing
University of Utah
Presentation Outline
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
1 Problem Statement
Statement
Scale Space
and Image
Kernels 2 Scale Space and Image Kernels
Corner
Detection
SIFT
3 Corner Detection
4 SIFT
Main paper to be discussed
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels David G. Lowe, Distinctive Image Features from
Corner
Detection
Scale-Invariant Keypoints, IJCV, 2004.
SIFT
How to find useful keypoints?
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman
How do you handle large scale changes?
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman
Problem Statement
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
Extract distinctive invariant features from images.
and Image
Kernels Perform reliable matching between different views of an
Corner object or scene.
Detection
SIFT
Provide invariance w.r.t scale changes, rotations, affine
distortions, viewpoints, noise, illumination.
Uses of SIFT
Keypoints and
Descriptors
Srikumar
Ramalingam
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
The invariant features can be matched against a large
Scale Space
and Image
database of features of known objects from many images.
Kernels
The matching can be done using a fast nearest-neighbor
Corner
Detection algorithm.
SIFT
Pose estimation can be used for verification purposes.
Can handle clutter and occlusion.
Searching for specific objects from movies
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman, Sivic, Zisserman
Searching for specific objects from movies
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman, Joseph Sivic and Andrew Zisserman
Repeatability
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman
Stages of generating SIFT features
Keypoints and
Descriptors
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
1 Problem Statement
Statement
Scale Space
and Image
Kernels 2 Scale Space and Image Kernels
Corner
Detection
SIFT
3 Corner Detection
4 SIFT
Detection of scale-space extrema
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem Search for stable features across all possible scales, using a
Statement
continuous function of scale known as scale space (Witkin,
Scale Space
and Image 1983).
Kernels
Corner
An image is represented as a one-parameter family of
Detection
smoothed images, the scale-space representation,
SIFT
parameterized by the size of the smoothing kernel used for
suppressing fine-scale structures.
Does it just correspond to the size of the image?
Why do we use the Gaussian function as the
scale-space kernel?
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
We sometimes want to look at a leaf and other times an
Scale Space
entire tree. If it’s a tree, we get rid of small details such as
and Image
Kernels
leaves and twigs. While getting rid of these small details,
Corner we must ensure that we do not introduce new false details.
Detection
Koenderink (1984) and Lindeberg (1994) showed that the
SIFT
only way to ensure this under reasonable assumptions is by
using Gaussian function as the only scale-space kernel.
0
Source: aishack.in
What is an image kernel?
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
A kernel, convolution matrix, or mask is a small matrix
Scale Space
and Image that is useful for blurring, sharpening, embossing, edge
Kernels
Corner
detection, and more.
Detection
This is accomplished by means of convolution between a
SIFT
kernel and an image.
0
Source: wikipedia.org
Identity kernel
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: wikipedia.org
Edge kernel
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: wikipedia.org
Box blur and Gaussian kernels
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: wikipedia.org
Scale Space using Gaussian kernel- Witkin 1983
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
An edge position may shift with increasing scale
Kernels
Two edges may merge with increasing scale
Corner
Detection
An edge may not split into two with increasing scale
SIFT
0
Source: Noah Snavely
Scale Space
Keypoints and
Descriptors
Srikumar
Ramalingam
1 −(x 2 +y 2 )
G (x, y , σ) = e 2σ 2
2πσ 2
Image kernel - Gaussian function
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: wikipedia.org
Image kernel - Gaussian function
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: aishack.in
SIFT - Scale Space and downsampling
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: aishack.in
Difference of Gaussians
Keypoints and
Descriptors
Srikumar
Ramalingam
Stable keypoint locations are detected using scale-space
Problem
Statement
extrema in the difference-of-Gaussian function convolved
Scale Space
with the image D(x, y , σ).
and Image
Kernels The diference of Gaussian is computed at two nearby
Corner scales separated by a constant multiplicative factor k.
Detection
SIFT
0
Source: aishack.in
Difference of Gaussians
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
For each octave of scale space, the initial image is
repeatedly convolved with Gaussians to produce the set of
scale space images shown on the left.
Adjacent Gaussian images are subtracted to produce the
difference-of-Gaussian images on the right.
After each octave, the Gaussian image is down-sampled by
a factor of 2, and the process repeated.
Laplacian of a Gaussian
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement We take an image and blur it a little using Gaussian
Scale Space function.
and Image
Kernels Calculate the second order derivatives or the Laplacian -
Corner
Detection
locates edges and corners that are good for detecting
SIFT
keypoints.
Computation of the second order derivative is also
extremely sensitive to noise, and the blurring helps.
Laplacian of a Gaussian
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
The laplacian of a Gaussian is represented as ∇2 G .
and Image
Kernels The scale-invariant laplacian of a Gaussian would be
Corner σ 2 ∇2 G .
Detection
SIFT
The difference of Gaussian images is approximately
equivalent to the laplacian of the Gaussian.
Locate maxima-minima in DoG images
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
Fit a 3D quadratic function to the local sample points to
SIFT
determine the interpolated location of the maximum.
The idea is to use the Taylor expansion of the scale-space
function:
δD T 1 δ2D
D(x) = D + x + xT 2 x
δx 2 δx
Here D and its derivates are evaluated at the sample point
and x = (x, y , δ)T is the offset from this point.
Removing low contrast features
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
If the intensity value (i.e., without sign) at the current
Scale Space
and Image pixel in the DoG image (that is being checked for
Kernels
Corner
minima/maxima) is less than a certain value, it is rejected.
Detection
The subpixel intensity value is computed using Taylor
SIFT
expansion and if it is less than a threshold, it is rejected.
0
Source: aishack.in
Presentation Outline
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
1 Problem Statement
Statement
Scale Space
and Image
Kernels 2 Scale Space and Image Kernels
Corner
Detection
SIFT
3 Corner Detection
4 SIFT
Corners as keypoints
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source:aishack.in
Harris corner detector
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT X
E (x, y ) = w (x, y )[I (x + u, y + v ) − I (x, y )]2
x,y
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
Let us consider the intensity change by moving a window
SIFT
by a small displacement:
X
E (x, y ) = w (x, y )[I (x + u, y + v ) − I (x, y )]2
x,y
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
X
Statement E (u, v ) ≈ w (x, y )[uIx + vIy ]2
Scale Space x,y
and Image
Kernels
X
E (u, v ) ≈ w (x, y )[u 2 Ix2 + v 2 Iy2 + 2uvIx Iy ]
Corner
Detection x,y
SIFT
Ix2
X Ix Iy u
E (u, v ) ≈ w (x, y ) u v
Ix Iy Iy2 v
x,y
0
Source:aishack.in
Harris corner detector
Keypoints and
Descriptors
Srikumar
Ramalingam
Ix2
Problem
X Ix Iy u
E (u, v ) ≈ w (x, y ) u v
Statement
Ix Iy Iy2 v
Scale Space x,y
and Image
Kernels u
Corner E (u, v ) ≈ u v M
Detection v
SIFT
where
Ix2
X Ix Iy
M= w (x, y )
Ix Iy Iy2
x,y
0
Source:aishack.in
Harris Corner Detector
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
Let α and β be the Eigenvalues of the matrix M. The
Eigenvalues determine the stability of a matrix.
R = det(M) − k(trace(M))2
det(M) = α × β
trace(M) = α + β
0
Source: Harris and Stevens, 1988
Harris Corner Detector
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
R = det(M) − k(trace(M))2
det(M) = α × β
trace(M) = α + β
If both eigenvalues are small, then the pixel is ”flat” (the
white region).
If one eigenvalue is large, and the other is small, then the
Images and 2D Derivatives
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
2D Derivatives as points
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Fit ellipses to the 2D derivatives
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Classification based on Eigen Values
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Corner Response Measure
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Robert Collins
Presentation Outline
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
1 Problem Statement
Statement
Scale Space
and Image
Kernels 2 Scale Space and Image Kernels
Corner
Detection
SIFT
3 Corner Detection
4 SIFT
Orientation assignment
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman
Keypoint Descriptors
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
At this point, each keypoint has
Statement location
Scale Space scale
and Image
Kernels orientation
Corner Next is to compute a descriptor for the local image region
Detection
about each keypoint that is
SIFT
highly distinctive
invariant as possible to variations such as changes in
viewpoint and illumination
0
Source: Kristen Grauman
Normalization
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image Rotate the window to standard orientation.
Kernels
Corner
Scale the window size based on the scale at which the
Detection point was found.
SIFT
0
Source: Kristen Grauman
Lowe’s Keypoint Descriptor
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
0
Source: Kristen Grauman
Lowe’s Keypoint Descriptor
Keypoints and
Descriptors
Srikumar
Ramalingam
Use the normalized region about the keypoint.
Problem
Statement Compute gradient magnitude and orientation at each
Scale Space point in the region.
and Image
Kernels Weight them by a Gaussian window overlaid on the circle.
Corner
Detection Create an orientation histogram over the 4x4 subregions of
SIFT the window.
4x4 descriptors over 16x16 sample arrays were used in
practice. 4x4 times 8 directions gives a vector of 128
values.
0
Source: Kristen Grauman
SIFT for matching objects
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
SIFT for matching objects
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Kernels
Corner
Detection
SIFT
Acknowledgments
Keypoints and
Descriptors
Srikumar
Ramalingam
Problem
Statement
Scale Space
and Image
Some presentation slides are adapted from David Lowe’s
Kernels landmark paper, Kristen Grauman, Andrew Zisserman, Joseph
Corner
Detection
Sivic, wikipedia.org, Robert Collins, and Utkarsh Sinha
SIFT (aishack.in)