Shortcut Learning in Medical Image Segmentation

Manxi Lin, Nina Weng, Kamil Wojciech Mikolaj, Zahra Bashir, Morten Bo Søndergaard Svendsen, Martin Grønnebæk Tolsgaard, Anders Nymark Christensen, Aasa Feragen

Introduction

Shortcut learning is a phenomenon in machine learning where models rely on simple, non-generalizable correlations in training data rather than learning the actual underlying features of interest. While extensively documented in image classification—such as models identifying pneumonia by hospital watermarks rather than lung pathology—the research community largely assumed that image segmentation was more resistant to this issue. The prevailing logic was that because segmentation requires precise, pixel-level boundary delineation, a model must inherently understand the anatomy to succeed.

This paper challenges that assumption, demonstrating that segmentation models are equally prone to latching onto "easy" cues like clinical measurement calipers or the spatial positioning of a lesion relative to the image border.

Identifying the Shortcut Problem

The authors investigate two distinct types of shortcuts prevalent in medical imaging tasks:

  1. Clinical Annotations in Ultrasound: Clinical images often contain text and measurement calipers. Models may learn to use these markers as a "trigger" for segmentation rather than identifying the organ itself.
  2. The Padding-Crop Interaction: Standard Convolutional Neural Networks (CNNs) use zero-padded convolutions, which inadvertently provide a "coordinate leak." If training datasets are predominantly center-cropped—a common practice—the model learns a spatial rule: foreground objects exist in the center, and anything near the border is background.
Visualizing shortcut learning: (Top) Clinical annotations like calipers act as a crutch in ultrasound. (Bottom) Center-bias in skin lesion datasets leads to failure when lesions are off-center.

Methodology

To analyze these shortcuts, the authors employed two common medical tasks:

  • Fetal Ultrasound Segmentation: Using a DTU-Net architecture, they compared a baseline model trained on standard clinical images against a mitigated model trained on "clean" images where annotations were removed via inpainting. The dataset consisted of 3,775 third-trimester images across 13 anatomical planes.
  • Skin Lesion Segmentation: Using a U-Net on the public ISIC2017 dataset, the authors explored how zero-padding allows models to "sense" image boundaries. They compared a model trained on center-cropped images ($M_{ori}$) against one trained with random cropping ($M_{crop}$) to break the spatial shortcut.

Key Insights and Failure Modes

The "Caliper Crutch"

In ultrasound, the model doesn't merely use calipers to refine boundaries; it becomes dependent on them. When calipers are absent—as they would be during a real-time scan—the model often fails to segment anything at all, leading to a massive spike in false negatives.

Breaking Translation Equivariance

Theoretically, CNNs should be translation equivariant, recognizing an object regardless of its position. However, the combination of zero-padding and "photographer bias" (the human tendency to center objects of interest) creates a spurious correlation. The model exploits the zero-values at the edges as a feature of the background class, effectively learning that the image border is a boundary for the object itself.

Key Results

Ultrasound Performance

Removing clinical annotations from the test set caused the Dice score for fetal head segmentation to drop significantly from 76.97 to 70.85. Conversely, the mitigated model trained on clean images achieved a much higher and more stable Dice score of 98.39, proving that removing the shortcut forces the model to learn more robust anatomical features.

Skin Lesion Robustness

The model trained on center-cropped images ($M_{ori}$) saw its performance plummet as lesions moved toward the image border. In contrast, the model trained with random cropping ($M_{crop}$) maintained high performance regardless of the lesion's position. This confirms that spatial shortcuts can be mitigated by diversifying the spatial distribution of the training data.

Impact of spatial shortcuts: The performance of the original model ($M_{ori}$) degrades as the lesion moves away from the center, while the mitigated model ($M_{crop}$) remains robust.

Conclusion and Future Work

The authors found that center-cropping is a dominant feature in major medical segmentation benchmarks, including LIDC-IDRI (lung), BraTS (brain), and Prostate MRI datasets. This suggests that many current state-of-the-art scores may be inflated by shortcut learning.

Future research is needed to determine if Vision Transformers (ViTs), which use positional encodings rather than padding, are susceptible to similar biases. Ultimately, the paper calls for the standardization of preprocessing steps—such as removing clinical markers and using random cropping—to ensure the clinical safety and reliability of medical AI.

Summary updated

BibTeX
@inproceedings{lin2024shortcut,
  author = {Manxi Lin and Nina Weng and Kamil Wojciech Mikolaj and Zahra Bashir and Morten Bo Søndergaard Svendsen and Martin Grønnebæk Tolsgaard and Anders Nymark Christensen and Aasa Feragen},
  title = {{Shortcut Learning in Medical Image Segmentation}},
  booktitle = {International Conference on Medical Image Computing and Computer-Assisted Intervention},
  year = {2024},
  doi = {10.1007/978-3-031-72111-3\_59},
}

Loading related content...

Figure