{ } Raw JSON

bundles / skimage 0.26.1rc0.dev0+git20260530.b607368ff / skimage / feature / corner / corner_foerstner

function

skimage.feature.corner:corner_foerstner

source: /dev/scikit-image/src/skimage/feature/corner.py :795

Signature

def   corner_foerstner ( image sigma = 1 )

Summary

Compute Foerstner corner measure response image.

Extended Summary

This corner detector uses information from the auto-correlation matrix A

A = [(imx**2)   (imx*imy)] = [Axx Axy]
    [(imx*imy)   (imy**2)]   [Axy Ayy]

Where imx and imy are first derivatives, averaged with a gaussian filter. The corner measure is then defined as

w = det(A) / trace(A)           (size of error ellipse)
q = 4 * det(A) / trace(A)**2    (roundness of error ellipse)

Parameters

image : ndarray of shape (M, N)

Input image.

sigma : float, optional

Standard deviation used for the Gaussian kernel, which is used as weighting function for the auto-correlation matrix.

Returns

w : ndarray

Error ellipse sizes.

q : ndarray

Roundness of error ellipse.

Examples

from skimage.feature import corner_foerstner, corner_peaks
square = np.zeros([10, 10])
square[2:8, 2:8] = 1
square.astype(int)
w, q = corner_foerstner(square)
accuracy_thresh = 0.5
roundness_thresh = 0.3
foerstner = (q > roundness_thresh) * (w > accuracy_thresh) * w
corner_peaks(foerstner, min_distance=1)

Aliases

  • skimage.feature.corner_foerstner