Fraunhofer HHI's MST-C Catches What AI Heatmap Metrics Miss
A new graph-based metric called MST-C measures how clustered and contained attribution maps are, catching structural flaws that older complexity scores miss.
Takeaways
- Mesgari, Ma, Samek, Lapuschkin and Weber introduce MST-C, a graph-based metric for attribution compactness.
- It combines minimum spanning tree edge length (cohesion) with convex hull area (spread) into one score.
- Correlates up to 0.85 with Sparseness on SimCLR and negatively with Complexity and Effective Complexity.
- Exposes a ResNet shortcut-connection artifact that inflates LRP-ε structural density compared to VGG-16.
- Evaluated on 250 PASCAL VOC images across supervised ResNet34, VGG-16 and self-supervised SimCLR backbones.
- Shows no correlation with correctness metrics RRA and ROAD, so it only measures legibility, not faithfulness.
Saliency and attribution maps assign importance scores to image pixels, helping practitioners inspect which regions influenced a vision model. Existing legibility metrics can measure how concentrated those scores are, yet they often ignore spatial arrangement. A compact object-shaped region and scattered noise may receive similar scores when their pixel-value distributions match.
Researchers Mohammad Mahdi Mesgari, Jackie Ma, Wojciech Samek, Sebastian Lapuschkin and Leander Weber from Fraunhofer HHI and TU Berlin address that gap in a recent paper. Their metric, MST-C, converts salient pixels into a spatial point cloud and measures how tightly those points cluster. The result adds geometric information to explainable AI benchmarks that currently depend on pixel statistics and visual inspection.
Heatmaps have a geometry problem
Attribution evaluation involves two independent questions. Faithfulness asks whether highlighted pixels influenced the model’s output. Legibility asks whether the resulting heatmap forms a clear, interpretable pattern. A useful evaluation suite needs separate measurements for both properties.
Legibility scores such as Sparseness, Complexity and Effective Complexity, available through Quantus, summarize attribution values pixel by pixel. Sparseness rewards concentration among fewer pixels, while high Complexity and Effective Complexity often indicate a uniform or noise-like distribution. These statistics do not encode the coordinates of the selected pixels.
MST-C adds that missing geometry through two components. Spread is the area of the convex hull, the smallest convex polygon enclosing all salient pixels. Cohesion is derived from the total length of a minimum spanning tree, the shortest cycle-free set of edges connecting every selected pixel. Broad regions enlarge the hull, and distant clusters require longer connecting edges. The final score assigns higher values to more compact maps.
Five steps from pixels to score
- Select salient pixels. Apply the paper’s thresholding rule and treat each retained pixel coordinate as a graph node.
- Build the neighborhood graph. Connect each node to its
knearest neighbors using Euclidean distance as the edge weight. - Confirm connectivity. The graph must contain one connected component before a minimum spanning tree can cover every node.
- Measure cohesion and spread. Sum the spanning tree’s edge lengths and calculate the convex hull area.
- Aggregate the components. Apply the paper’s normalization and combination equations so shorter trees and smaller hulls produce a higher MST-C value.
Exact reproduction requires consistent thresholding, coordinate scaling, normalization and score aggregation. Replacing normalized quantities with raw tree length or hull area changes both the scale and comparability of the result.
The neighborhood size k determines whether the graph is connected and how much work the algorithm performs. The authors sweep candidate values through 1,500 and report stable scores after the graph becomes sufficiently connected. At k=500, every test graph forms a single component, and one iteration takes roughly 2.5 seconds in their setup. Different image resolutions, thresholds and graph implementations may require another value.
The metric agrees, then adds signal
The evaluation covers 250 images across 20 object classes, with attribution maps generated from supervised and self-supervised models.
| Dimension | Evaluated setup |
|---|---|
| Models | ResNet34, VGG-16 and a self-supervised SimCLR configuration |
| Attribution methods | GradCAM, Integrated Gradients, SHAP and several LRP composites |
| Legibility comparisons | Sparseness, Complexity and Effective Complexity |
| Correctness comparisons | Relevance rank accuracy and ROAD |
MST-C reaches a positive correlation of up to 0.85 with Sparseness for the LRP-ε-z+-flat composite in the SimCLR setup. It generally correlates negatively with Complexity and Effective Complexity. Those directions match the metrics’ definitions: concentrated attribution produces higher Sparseness and MST-C values, while diffuse attribution raises Complexity.
Pairs of maps with nearly identical Sparseness, Complexity and Effective Complexity scores can receive substantially different MST-C values. Their attribution histograms may match even when highlighted pixels form a dense cluster in one map and several distant islands in another. MST-C captures that spatial difference.
Artifacts can look compact
GradCAM records the highest reported overall compactness score, reaching 265.03 on ResNet. Its short spanning trees and small convex hulls reflect the method’s coarse, localized heatmaps.
The ResNet results for LRP-ε are also comparatively high. The authors’ inspection of the heatmaps suggests that downsampling and shortcut connections introduce structured patterns that increase apparent attribution density. A backbone artifact can therefore raise MST-C even when the explanation method itself has not become more legible.
Compactness leaves correctness open
MST-C shows no consistent correlation with relevance rank accuracy, a localization measure, or ROAD, a perturbation-based faithfulness measure. Its scope is geometric legibility: the score indicates whether selected pixels form a compact pattern.
A crisp cluster in an irrelevant corner can still receive a high MST-C score. Model evaluations should pair it with localization or faithfulness tests before drawing conclusions about explanation quality.
Small choices move the score
Thresholding converts the attribution map into a set of active coordinates, discarding differences in attribution magnitude among those pixels. Maps with the same active set receive the same geometric input even when their intensity rankings differ.
| Implementation choice | Effect on MST-C |
|---|---|
| Threshold and sign handling | Changes which positive, negative or high-magnitude attributions become graph nodes. |
| Coordinate scale | Changes Euclidean distances and convex hull areas, especially when maps have different resolutions. |
| Neighborhood size | Controls graph connectivity, memory use and runtime. |
| Degenerate maps | Empty and single-point maps have no conventional spanning tree, while fewer than three non-collinear points have no positive hull area. |
| Convex hull geometry | Includes empty space inside concave shapes and between separated clusters. |
| Normalization | Determines whether scores remain comparable across images, models and datasets. |
Comparable benchmarks should publish these settings and define explicit behavior for empty, collinear and near-zero-area inputs. They should also hold image resolution and preprocessing constant across methods.
Where MST-C fits
MST-C works best as one column in a broader attribution benchmark. It supplies a scalar measure of spatial compactness, existing legibility metrics describe the distribution of attribution values, and faithfulness or localization tests assess whether the highlighted region is relevant to the model’s decision.
Standard scientific Python components can cover the main implementation steps: nearest-neighbor search, sparse-graph minimum spanning trees and convex hull computation. Production code still needs safeguards for disconnected graphs, degenerate point sets, memory use at large k and reproducible preprocessing.
The paper is scheduled to appear in the proceedings of the 4th World Conference on Explainable Artificial Intelligence, xAI 2026. Its abstract does not identify a public implementation, so independent implementations will need to follow the published thresholding, normalization and aggregation equations closely.