Abstract
Medical data poses a daunting challenge for AI algorithms: it exists in many different modalities, experiences frequent distribution shifts, and suffers from a scarcity of examples and labels. Recent advances, including transformers and self-supervised learning, promise a more universal approach that can be applied flexibly across these diverse conditions. To measure and drive progress in this direction, we present BenchMD: a benchmark that tests how well unified, modality-agnostic methods, including architectures and training techniques (e.g. self-supervised learning, ImageNet pretraining), perform on a diverse array of clinically-relevant medical tasks. BenchMD combines 19 publicly available datasets for 7 medical modalities, including 1D sensor data, 2D images, and 3D volumetric scans. Our benchmark reflects real-world data constraints by evaluating methods across a range of dataset sizes, including challenging few-shot settings that incentivize the use of pretraining. Finally, we evaluate performance on out-of-distribution data collected at different hospitals than the training data, representing naturally-occurring distribution shifts that frequently degrade the performance of medical AI models. Our baseline results demonstrate that no unified learning technique achieves strong performance across all modalities, leaving ample room for improvement on the benchmark. Code is released at https://github.com/rajpurkarlab/BenchMD.
Introduction
In the world of medical AI, specialization is currently the status quo. Separate models are typically engineered for X-rays, EKGs, and CT scans, leading to significant inefficiencies. Every new clinical task requires a custom-built pipeline, specific data augmentations, and extensive hyperparameter tuning.
Recent breakthroughs in "unified" learning—specifically Transformers and Self-Supervised Learning (SSL)—promise a more universal approach. Theoretically, these models should be able to process any data type "out-of-the-box." However, the medical domain presents unique hurdles: extreme modality diversity (from 1D signals to 3D volumes), scarcity of expert labels, and frequent distribution shifts between hospitals. BenchMD provides a rigorous framework to measure how these universal methods actually stack up across the full spectrum of clinical data.
The BenchMD Benchmark
BenchMD standardizes 19 publicly available datasets into a unified evaluation framework spanning seven modalities. This includes 1D sensors (ECG, EEG), 2D images (Chest X-ray, Mammography, Dermoscopy, Fundus), and 3D volumetric scans (Low-dose CT).
The benchmark specifically pairs "source" datasets for training with "target" datasets for out-of-distribution (OOD) testing to simulate real-world hospital transfers, where equipment or demographics may differ significantly from the training environment.
Methodology
To evaluate the "unified" learning paradigm, the authors utilized a modality-agnostic Transformer architecture. Separate embedding modules map 1D, 2D, and 3D inputs into a shared 256-dimensional space, allowing a single core Transformer backbone to process diverse inputs without modality-specific architectural changes.
Five baseline training strategies were evaluated:
- Training from Scratch: No pretraining.
- ImageNet Pretraining: Leveraging natural images (for 2D modalities).
- Self-Supervised Learning (SSL): Including Masked Autoencoding (MAE), Contrastive Embedding-Mixup (e-Mix), and Shuffled Embedding Prediction (ShED).
Evaluation focuses on two clinically impactful scenarios: few-shot learning (training with as few as 8 labels per class) and zero-shot transfer to OOD data.
Key Insights and Results
The baseline results reveal several critical findings regarding the current state of unified learning:
- No Universal Winner: No single SSL technique dominates across all modalities. For instance, ShED performed excellently on ECG and CT scans but struggled with fundus images, while MAE excelled on EEG but faced challenges with ECG.
- ImageNet's Persistence: Despite being trained on natural images like cats and cars, ImageNet-pretrained models remain highly competitive on 2D medical images, often outperforming medical-specific SSL methods.
- The Unified Gap: The performance discrepancy across modalities suggests that a truly universal training objective capturing the nuances of all medical data types has yet to be discovered.
- Brittleness to Distribution Shifts: Models often show significant performance degradation on OOD data, even when in-distribution performance is high. This highlights the need for models that generalize across both modalities and clinical environments.
Specifically, SSL generally provides a significant boost over training from scratch in few-shot settings. ShED achieved the highest AUROC on ECG (0.737) and LDCT (0.783), while MAE led in EEG (0.758). ImageNet pretraining was the most consistent winner for Chest X-rays, Mammography, and Fundus images.
Conclusion
While BenchMD demonstrates the potential of modality-agnostic architectures, it also highlights a massive "room for improvement." Current methods still rely on modality-specific embedding modules. Future work may explore truly unified models using single patch-based embeddings for all data types or pretraining on natural video to better support 3D medical volumes. BenchMD serves as a call to the community to develop more robust unified learning techniques capable of handling the diverse and shifting nature of global healthcare data.
Summary updated