The -display_tensors command visualizes 2x2 tensor fields, taking such as input operands. For each pixel (tensor) in the field, the command renders an ellipse with axes that are proportional to the two eigenvalues. The semimajor axis aligns with the the steepest gradient in the locale and the eigenvector pointing along it.
Especially flat or highly eccentric ellipses reflect large differences in the magnitude of the two eigenvalues. The relative discrepancy of the two eigenvalues reflects the degree of anisotropy or bias toward a particular orientation. Rounder ellipses arise from eigenvalues closer together in value and reflect gradients that are not as strongly oriented in a particular direction.
The overall saturation and luminance of the ellipse reflect the magnitude of the largest eigenvalue and the rapidity of change of the local gradient.
As a practical matter, the command works best on relatively small images. Tensor maps with ≈1000 pixel dimensions can take some minutes to display and may furnish too much information for ready comprehension. It is generally easier to locate an area of interest in an earlier rendering pass, then crop the region of interest to image sizes of about 100 pixels or less, then render these excerpts with -display_tensors.
The accompanying illustration visualizes the structure tensor field of the 32x32 pixel excerpt from a larger gray scale image, far upper left, here magnified 4 times. The near upper left image is a structure tensor field of that excerpt; -display_tensor produced the visualization of this field, the large bottom illustration. The two small images near and far right are the output images of -eigen, here for comparison.
-display_tensors take the following parameters:
Garry Osgood