Average accuracy can hide who a model leaves behind.
Medical classifiers can learn shortcuts from the environments in which data are collected. A model may associate a hospital's imaging style, a scanner setting, or a demographic pattern with disease—even when that cue is not clinically meaningful.
These shortcuts are easy to miss. Overall performance can remain high while accuracy drops sharply for a particular site or patient subgroup.
The groups that matter for fair performance are often the same groups that are missing, incomplete, or too sensitive to use as training supervision.
DPE-Former is designed around that practical constraint. It explores latent variation through multiple class prototypes, then learns how those different views should contribute to each final prediction.
Complementary experts, coordinated by attention.
Learn the representation
A supervised encoder maps each image or clinical record into a compact feature embedding.
Diversify the prototypes
Prototype heads are trained on balanced subsets and regularized to explore distinct regions of the feature space.
Aggregate with a transformer
Self-attention captures relationships between prototype predictions and replaces a fixed ensemble average with an adaptive decision.
One framework, three kinds of clinical shift.
The study tests DPE-Former across imaging and structured clinical data, with each domain exposing a different source of hidden population imbalance.
Prostate cancer
Acquisition-site differences across clinical centres.
Skin lesions
Visual, class, and demographic imbalance in HAM10000.
Cardiac treatment
Latent treatment subgroups in structured clinical records.
Across the study settings, DPE-Former improves performance for underrepresented groups and produces more consistent subgroup behavior than the comparison methods considered in the paper.
This work is a research framework, not a medical device. Any clinical application requires independent external validation, governance review, and appropriate regulatory oversight.

