Why Invariance is Not Enough for Biomedical Domain Generalization and How to Fix It
Organizations: MIT · MIT, MGH, HMS
Abstract
We present MaskGen, a theoretically grounded and deliberately simple approach for domain generalization in 3D biomedical image segmentation. Modern segmentation models degrade sharply under shifts in modality, disease severity, clinical sites, and more, limiting their reliable adoption. Existing generalization methods address this using extreme augmentations, hand-engineered domain statistics mixing, or architectural redesigns that add significant implementation overhead while yielding inconsistent performance across biomedical settings. MaskGen instead presents a principled learning strategy with marginal overhead that utilizes both source-domain image intensities and domain-stable foundation model representations to train robust segmentation models. As a result, MaskGen achieves strong gains in both fully supervised and few-shot segmentation across broad clinical shifts in biomedical studies. Unlike prior approaches, MaskGen is architecture- and loss-agnostic, compatible with standard augmentation pipelines, easy to implement, and tackles arbitrary anatomical regions. Its implementation is freely available at https://github.com/sebodiaz/MaskGen.
Figures & tables
| Method | AMOS Ji et al. (2022) Modality | BraTS Antonelli et al. (2022) Sequence | CoW Yang et al. (2024) Modality | HVSMR Pace et al. (2024) Disease | PanDG Zhang et al. (2025) Phase | Prostate Liu et al. (2021) Site | Avg. Rank |
|---|---|---|---|---|---|---|---|
| ERM | 57.4 (1.7) | 38.9 (1.8) | 24.6 (1.5) | 63.6 (3.0) | 25.3 (2.5) | 83.0 (0.7) | 8.0 |
| GIN Ouyang et al. (2022) | 65.1 (0.7) | 29.9 (1.6) | 17.9 (1.5) | 64.1 (3.0) | 41.1 (1.8) | 82.1 (0.8) | 7.2 |
| GIN+IPA Ouyang et al. (2022) | 64.7 (2.6) | 50.3 (1.4) | |||||
| MixUp Zhang et al. (2017) | 61.5 (0.9) | 41.2 (1.7) | 36.3 (1.5) | 64.5 (3.2) | 26.7 (2.5) | 82.5 (0.7) | 5.5 |
| CutOut DeVries and Taylor (2017) | 55.5 (1.7) | 41.8 (1.6) | 26.5 (1.9) | 64.9 (3.5) | 30.5 (2.4) | 84.0 (0.6) | 5.0 |
| DSBN Zhou et al. (2022) | 58.0 (1.4) | 40.5 (1.7) | 29.6 (1.9) | 26.3 (2.6) | 83.4 (0.6) | 5.2 |
| Method | AMOS Modality | CoW Modality | HVSMR Disease | Prostate Site |
|---|---|---|---|---|
| ERM | 5.4(1.0) | 18.2(1.3) | 40.4(3.8) | 27.8(5.0) |
| GIN | 6.0(0.7) | 13.4(1.1) | 20.3(4.3) | |
| GINIPA | (1.7) | (3.8) | (5.1) | |
| MixUp | (1.6) | (3.9) | ||
| CutOut | 8.4(1.1) | 18.2 (1.4) | 41.3(3.6) | 40.8(4.5) |
| DSBN | (1.8) | (1.5) | (3.7) | (5.2) |
| Dataset | Model | 0.0 | 0.25 | 0.50 | 0.75 | RepOnly |
|---|---|---|---|---|---|---|
| AMOS Ji et al. (2022) | nnInteract. Isensee et al. (2025) | 64.3 | 65.0 | 65.9 | 66.4 | 63.9 |
| anatomix Dey et al. (2025) | 65.1 | 65.8 | 66.6 | 67.4 | 64.4 | |
| BraTS Antonelli et al. (2022) | nnInteract. Isensee et al. (2025) | 41.5 | 43.4 | 44.2 | 42.9 | 42.7 |
| anatomix Dey et al. (2025) | 41.7 | 42.5 | 47.2 | 47.2 | 41.3 | |
| CoW Yang et al. (2024) | nnInteract. Isensee et al. (2025) | 48.7 | 45.9 | 48.9 | 50.8 | 50.7 |
| anatomix Dey et al. (2025) | 49.0 | 49.5 | 51.0 | 52.2 | 51.7 |
| Method | Adaptation Needed? | AMOS Modality | BraTS Sequence | CoW Modality | HVSMR Disease | PanDG Phase | Prostate Site | Avg. Rank |
|---|---|---|---|---|---|---|---|---|
| EntMin (ERM) Wang et al. (2020) | Yes | 64.7 (1.2) | 38.9 (1.8) | 24.4 (1.5) | 64.4 (2.9) | 27.7 (2.4) | 84.5 (0.5) | 4.2 |
| EntMin (MR=0%) Wang et al. (2020) | Yes | 45.1 (1.2) | 65.0 (2.8) | 83.6 (0.5) | ||||
| SFB Eastwood et al. (2023) | Yes | 63.6 (1.0) | 38.8 (1.6) | 41.0 (1.3) | 65.2 (2.6) | 30.4 (2.5) | 85.4 (0.5) | 3.3 |
| Alpha Tuning Jiang and Veitch (2022) | Yes | 64.1 (1.3) | 41.7 (1.8) | 64.8 (3.3) | 28.5 (2.5) | 84.3 (0.5) | 3.2 | |
| Ours | No | 67.5 (0.9) | 46.2 (1.6) | 65.8(3.4) | 46.0 (1.9) | 1.3 |
| Dataset | All-data Setting | Few-shot Setting | ||||||
|---|---|---|---|---|---|---|---|---|
| AMOS Ji et al. (2022) | 65.1 | 65.8 | 66.6 | 67.4 | 23.5 | 41.9 | 50.8 | 53.6 |
| BraTS Antonelli et al. (2022) | 41.7 | 42.5 | 47.2 | 47.2 | – | – | – | – |
| CoW Yang et al. (2024) | 49.0 | 49.5 | 51.0 | 52.2 | 39.0 | 43.5 | 37.7 | 43.0 |
| HVSMR Pace et al. (2024) | 61.7 | 62.6 | 63.5 | 62.0 | 43.4 | 44.4 | 45.3 | 44.5 |
| PanDG Zhang et al. (2025) | 51.8 | 60.2 | 60.6 | 60.1 | – | – | – | – |
Appendix figures & tables13 assets
Supplementary material from the paper’s appendix.
Appendix
| Method | AMOS [ 22 ] | BraTS [ 34 , 1 ] | CoW [ 53 ] | HVSMR [ 36 ] | PanDG [ 57 ] | Prostate [ 32 ] |
|---|---|---|---|---|---|---|
| F.T. Extractor | 56.8 (1.5) | 37.7 (1.7) | 17.3 (1.7) | 64.6 (3.2) | 23.7 (2.6) | 84.2 (0.5) |
| F.T. Decoder | 57.2 (1.5) | 39.5 (1.7) | 18.5 (1.7) | 63.2 (2.9) | 27.7 (2.6) | 83.8 (0.7) |
| Ours | 67.5 (0.9) | 46.2 (1.6) | 47.8 (1.3) | 65.8 (3.4) | 46.0 (1.9) | 84.7 (0.5) |
| Ablations | AMOS [ 22 ] | BraTS [ 34 , 1 ] |
|---|---|---|
| Squeeze+Excite [ 15 ] | 64.3 (1.1) | 38.8 (1.7) |
| Ours | 67.5 (0.9) | 46.2 (1.6) |
| Method | AMOS [ 22 ] Modality | BraTS [ 1 ] Sequence | CoW [ 53 ] Modality | HVSMR [ 36 ] Disease | PanDG [ 57 ] Phase | Prostate [ 32 ] Site | Avg. Rank |
|---|---|---|---|---|---|---|---|
| ERM | 57.4 (1.7) | 38.9 (1.8) | 24.6 (1.5) | 63.6 (3.0) | 25.3 (2.5) | 83.0 (0.7) | 8.0 |
| GIN [ 35 ] | 65.1 (0.7) | 29.9 (1.6) | 17.9 (1.5) | 64.1 (3.0) | 41.1 (1.8) | 82.1 (0.8) | 7.2 |
| GIN+IPA [ 35 ] | 64.7 (2.6) | 50.3 (1.4) | |||||
| MixUp [ 55 ] | 61.5 (0.9) | 41.2 (1.7) | 36.3 (1.5) | 64.5 (3.2) | 26.7 (2.5) | 82.5 (0.7) | 5.5 |
| CutOut [ 8 ] | 55.5 (1.7) | 41.8 (1.6) | 26.5 (1.9) | 64.9 (3.5) | 30.5 (2.4) | 84.0 (0.6) | 5.0 |
| DSBN [ 62 ] | 58.0 (1.4) | 40.5 (1.7) | 29.6 (1.9) | 26.3 (2.6) | 83.4 (0.6) | 5.2 |
| Method | AMOS Modality | CoW Modality | HVSMR Disease | Prostate Site | Avg. Rank |
|---|---|---|---|---|---|
| ERM | 5.4 (1.0) | 18.2 (1.3) | 40.4 (3.8) | 27.8 (5.0) | 8.0 |
| GIN | 6.0 (0.7) | 13.4 (1.1) | 20.3(4.3) | 6.5 | |
| GINIPA | (1.7) | (3.8) | (5.1) | 3.5 | |
| MixUp | (1.6) | (3.9) | 3.5 | ||
| CutOut | 8.4 (1.1) | 18.2 (1.4) | 41.3 (3.6) | 40.8 (4.5) | 5.5 |
| DSBN | (1.8) | (1.5) | (3.7) | (5.2) | 3.5 |
| Block | Contents |
|---|---|
| 0 | Conv-BN-ReLU( ) |
| 1 | Conv-BN-ReLU( ) |
| 2 | Conv-BN-ReLU( ) |
| 3 | MaxPool(2), Conv-BN-ReLU( ) |
| 4 | Conv-BN-ReLU( ) |
| 5 | Conv-BN-ReLU( ) |
| Dataset | Crop Size | Spacing (mm) | # Train | # Val. | # Test |
|---|---|---|---|---|---|
| AMOS | |||||
| BraTS | |||||
| CoW | |||||
| HVSMR | |||||
| PancreasDG | |||||
| Prostate |