Main Content

detectKAZEFeatures

Detect KAZE features and return KAZEPoints object

Description

example

points = detectKAZEFeatures(I) returns a KAZEPoints object containing information about KAZE keypoints detected in a 2-D grayscale image. The function uses nonlinear diffusion to construct a scale space for the given image. It then detects multiscale corner features from the scale space.

points = detectKAZEFeatures(I,Name,Value) returns a KAZEPoints object with additional options specified by one or more Name,Value pair arguments

Examples

collapse all

Detect and plot KAZE feature points.

Read an image.

I = imread('cameraman.tif');

Detect KAZE points in the image.

points = detectKAZEFeatures(I);

Plot the 20 strongest points.

imshow(I)
hold on
plot(selectStrongest(points,20))
hold off

Figure contains an axes object. The axes object contains 3 objects of type image, line.

Detect KAZE features and display set the specific KAZE points you want to plot.

Read an image.

I = imread('cameraman.tif');

Detect KAZE features in the image.

points = detectKAZEFeatures(I);

Select and display the last 5 points detected.

imshow(I);
hold on;
plot(points(end-4:end));
hold off;

Figure contains an axes object. The axes object contains 3 objects of type image, line.

Input Arguments

collapse all

Input image, specified as a 2-D grayscale image.

Data Types: single | double | int16 | uint8 | uint16 | logical

Name-Value Arguments

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Before R2021a, use commas to separate each name and value, and enclose Name in quotes.

Example: 'Diffusion','region'

Method to compute conductivity, specified as 'region', 'sharpedge', or 'edge'. The computation is based on first-order derivatives of a layer in scale space.

MethodSelected Features
'region'Large regions. Uses the Perona and Malik conductivity coefficient, 1/(1 + dL^2/k^2).
'sharpedge'High-contrast edges. Uses the Perona and Malik conductivity coefficient, exp(-|dL|^2/k^2).
'edge'Smoothing on both sides of an edge rather than across it. Uses the Weickert conductivity coefficient.

Local extrema, specified as a scalar greater than or equal to 0. Increase this value to exclude less significant local extrema.

Multiscale detection factor, specified as a positive integer. Increase this value to detect larger features. To disable multiscale detection, set NumOctaves to 1. When you set the value to 1, the function detects the scale of the input image. Recommended values are between 1 and 4.

Scale levels, specified as an integer in the range [3,10]. Increase this value to achieve smoother scale changes. Increasing this value also provides additional intermediate scales between octaves.

Rectangular region size for corner detection, specified as a 4-element vector in the format [y x width height]. The [y x ] values are measured from the upper left corner of the rectangle.

Output Arguments

collapse all

KAZE points, returned as a KAZEPoints object. The object contains information about the feature points detected in the 2-D grayscale input image.

References

[1] Alcantarilla, P.F., A. Bartoli, and A.J. Davison. "KAZE Features." ECCV 2012, Part VI, LNCS 7577. 2012, p. 214

Extended Capabilities

Version History

Introduced in R2017b