NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Label leakage through file headers: geometry and batch confounds in public mammography datasets, and a pre-training acceptance gate

Achraf Toufah, Rana Saad, Moulay Youssef El HafidiarXiv 2026

TL;DR

Imagine training a cutting-edge AI to detect breast cancer, celebrating its near-perfect accuracy, and then realizing it never actually looked at the anatomy—it just read the image dimensions from the file header. This paper audits six popular public mammography datasets and reveals that in several of them, diagnostic labels can be reliably predicted from trivial metadata like file dimensions, compression artifacts, or patient ID numbers. To prevent wasted compute and hollow breakthroughs, the authors introduce a lightweight, pre-training "acceptance gate" to catch these shortcuts before a neural network ever sees a pixel.

What Problem Does This Paper Address?

In machine learning, models are notorious for "shortcut learning" (or the "Clever Hans" effect)—latching onto easy, spurious correlations rather than true underlying signals. In medical imaging, models have previously been caught predicting diagnoses by recognizing hospital scanner signatures or surgical skin markings rather than disease.

If a dataset's diagnostic label is accidentally encoded in how the files were exported, cropped, or numbered, every model trained on it—classical or quantum, simple or massive—will achieve high, reproducible scores that say nothing about human biology. While dataset documentation checklists exist, documentation alone doesn't test whether a file whispers its label to the classifier. Researchers need a fast, empirical sanity check at data intake.

Methods

Instead of inventing a complex new algorithm, the authors propose an operational procedure: a pre-training acceptance gate. Before training any deep model, you train an off-the-shelf, deliberately untuned gradient-boosting classifier (HistGradientBoostingClassifier) on "impoverished" inputs—features that should contain zero diagnostic value.

Summary of the five pre-training controls and their stop rules

Performance is measured via AUC (Area Under the ROC Curve, where 0.50 is random guessing and 1.00 is perfection). If any "stop" control hits or exceeds an AUC of 0.60, you halt the study and investigate the data:

  • Geometry: Reads only four integers from the file header (width, height, megapixels, aspect ratio)—no pixels decoded.
  • Texture: Computes four basic global statistics (sharpness, gradient energy, intensity standard deviation, contrast) after resizing images to a uniform square.
  • Batch / Site: Uses only the sub-collection prefix from the patient ID.
  • Identifier Order: Added post hoc, using only the numeric serial number of the patient ID.
  • Single Covariate (Context only): Tests a demographic variable like age. Because age genuinely correlates with cancer in clinical cohorts, this sets a baseline floor rather than stopping a study.

Datasets

No new datasets were created; instead, the authors audited six existing public mammography benchmarks across initial and follow-up rounds:

  • KAU-BCMD (analyzed via both a local PNG copy and a public Kaggle JPEG archive)
  • CMMD (Chinese Mammography Database, analyzed pooled and restricted to sub-collection D1)
  • CBIS-DDSM (digitized film mammograms)
  • INbreast (digital mammograms)
  • VinDr-Mammo (an incomplete 59.8% download of the release)
  • M-SYNTH (an FDA-distributed simulated cohort, balanced by construction)
Follow-up round datasets and configurations

Key Insights and Ideas

  • Resizing images does not erase their history: You might think resizing all images to 224 × 224 fixes a geometry leak. On KAU-BCMD, it didn't. Resampling high-resolution negative scans and low-resolution positive scans to the same dimensions leaves behind distinct frequency and compression signatures that a basic texture classifier easily exploits.
  • Pooling data creates invisible batch channels: CMMD comprises two sub-collections—one ~51% malignant, the other ~98% malignant. Pooling them without controlling for the source hands any downstream model a massive shortcut.
  • Passing a gate is not a clean bill of health: When the authors restricted CMMD to its first sub-collection (D1), it passed both the geometry and texture gates. Later, they checked patient ID serial numbers and found the spreadsheet was ordered in long streaks of identical diagnoses! A gate only catches what you think to test for; it provides a lower bound on leakage, never a certificate of purity.

Key Results

  • KAU-BCMD: Failed dramatically. Positive and negative classes shared zero image dimensions. Geometry alone predicted BI-RADS classes at AUC 1.0000 (local copy) and 0.9790 (public Kaggle archive). After resizing to 224 × 224, texture alone still scored 0.8465 on the public archive.
  • CMMD: Passed geometry (0.5000, as all images are 2294 × 1914), but failed batch prefix when pooled (0.7753). Restricting to sub-collection D1 passed texture (0.5810), but failed the post hoc identifier-order check at a staggering 0.9926 test AUC.
  • CBIS-DDSM: Exceeded the geometry threshold across 20 repeated splits (0.6543 pooled mean), though its single official mass (0.5884) and calcification (0.5625) splits stayed below 0.60. Additionally, pooling the two official cohorts leaked 31 overlapping patients across train and test sets.
  • Passes: M-SYNTH (0.5070 physics features, 0.5000 metadata), INbreast (0.4863 geometry), and the partial VinDr-Mammo copy (0.5732 geometry) passed the few controls run on them.

Limitations and Future Work

The authors are remarkably candid about their study's boundaries:

  • Post hoc choices & missing scripts: Several controls (batch, ID order) and the 20-split mean verdict statistic were chosen after seeing initial anomalies, making parts of the gate retrospective. Furthermore, original scripts for the initial round were lost (reconstructed from notes), and protocols varied across datasets.
  • Incomplete coverage: Not all controls were run on all datasets (INbreast and VinDr-Mammo only saw the geometry check), two planned datasets (RSNA, BreastMNIST) were skipped, and VinDr-Mammo/CBIS-DDSM copies were incomplete.
  • Downstream impact unmeasured: The paper proves these shortcuts exist in the files, but doesn't measure how much a standard deep neural network's AUC actually drops when the leaking channels are neutralized.

Moving forward, the authors recommend a simple, low-cost habit for the medical AI community: run file-level controls at intake, watch out for patient overlap and record ordering, and publish those baseline control AUCs right alongside your model's results.

Summary updated

BibTeX
@misc{toufah2026label,
  author = {Achraf Toufah and Rana Saad and Moulay Youssef El Hafidi},
  title = {{Label leakage through file headers: geometry and batch confounds in public mammography datasets, and a pre-training acceptance gate}},
  year = {2026},
  eprint = {2611.32899},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.32899},
}
Figure