Harris invariance

Good interest points are repeatable: they are found again when the same scene is seen with different lighting or from a different viewpoint. Transform an image, run the Harris detector on both versions independently, and count how many corners come back.

Original AA found again lost
Transformed BB corners of B rings: corners of A, mapped
Rotation θ found again corners of B with a partner
Scale s each curve changes one parameter only
Contrast a
Brightness b

Invariance and covariance

Two different properties are wanted from a detector, depending on the kind of change:

Affine intensity change

An affine intensity change adjusts the contrast with a gain aa and the brightness with an offset bb:

I′(x,y)=a I(x,y)+bI'(x, y) = a \, I(x, y) + b

The Harris detector only uses derivatives, so the offset disappears: I→I+bI \to I + b leaves every corner in place. The gain scales the derivatives by aa, the second moment matrix MM by a2a^2 and the cornerness C=det⁡(M)−αtrace⁡(M)2C = \det(M) - \alpha \operatorname{trace}(M)^2 by a4a^4. The maxima of CC stay where they are, but a fixed threshold now cuts at a different level: with lower contrast the weaker corners are lost, with higher contrast new ones get through. The detector is therefore only partially invariant to affine intensity changes. In practice, values are also clipped at black and white, and in saturated regions the image content itself is gone.

Translation and rotation

Derivatives and the window function are shift-invariant, so the corner locations are covariant with translation. When the image rotates, the second moment ellipse rotates with it, but its shape, and so the eigenvalues, stay the same. The cornerness depends only on the eigenvalues, so the corner locations are covariant with rotation as well. The small losses at angles between multiples of 90° come from resampling the image on the rotated pixel grid.

Scaling

Imagine a rounded corner that fits inside the window. Scale the image up and the corner spills out of the window: every window along it now sees an almost straight edge, and all points are classified as edges. The corner is lost. Scaling down merges fine structures, such as small squares, into one blob with different corners. And where a corner survives, the detector places it relative to its window, so its position no longer maps exactly onto the corner in the other image. The Harris corner locations are not covariant with scaling, because the window has a fixed size in pixels. Detectors for matching between images of different scale also have to choose the size of the window per point, by searching in scale space as well, for example with the Difference of Gaussians.

Measuring repeatability

Both images are processed independently with the same detector settings. Only corners in the region that both images show count, at a distance from the borders where the filters would see pixels outside the image. Each corner of AA is mapped into BB with the known transformation and paired with a corner of BB at most ε\varepsilon pixels away, closest pairs first and each corner at most once. The share of corners of AA that are found again is the repeatability; the dashed curves show which share of the corners of BB has a partner in AA. The four plots change one parameter at a time, the others staying at the identity.

Try this