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

Domain Generalization with Small Data

Kecheng Chen, Elena Gal, Hong Yan, Haoliang Li

Introduction

Domain Generalization (DG) is a critical challenge in machine learning, aiming to train models on multiple "source" domains such that they generalize effectively to unseen "target" domains. While many DG methods exist, their primary weakness is a heavy reliance on large-scale datasets. In fields like medical imaging, data is often scarce due to privacy regulations, rare conditions, or the high cost of expert labeling.

Standard deterministic models often produce brittle feature representations when trained on small datasets, leading to poor generalization. This paper addresses this "small data" bottleneck by proposing a probabilistic framework that replaces deterministic point embeddings with latent distributions.

Methodology: Probabilistic Alignment

The core innovation of this work is the shift from mapping images to single vectors to mapping them to probabilistic embeddings. By using Bayesian Neural Networks (BNNs), the model naturally captures the uncertainty inherent in sparse data.

The proposed probabilistic framework illustrating the mapping of domains to latent distributions and the calculation of P-MMD in the Reproducing Kernel Hilbert Space (RKHS).

Key Components:

  1. Probabilistic Embeddings: Instead of a single point, each image is represented as a distribution, allowing the model to account for feature uncertainty.
  2. P-MMD (Probabilistic Maximum Mean Discrepancy): This global alignment loss measures the discrepancy between mixtures of latent distributions across different domains. It extends standard MMD to handle "distributions over distributions."
  3. P-CSA (Probabilistic Contrastive Semantic Alignment): A local alignment strategy that uses a contrastive loss to pull together probabilistic embedding pairs of the same class from different domains while pushing apart negative pairs.
  4. Variational Inference: The model employs Monte Carlo sampling to approximate the posterior distribution of network weights, ensuring robustness in low-sample regimes.

Experimental Setup and Datasets

The researchers focused on medical imaging tasks where domain shift is prevalent and data is limited.

Examples of histopathological images from the NKI, IHC, and VGH domains used for Epithelium-Stroma classification, showcasing significant visual variance across centers.

Key datasets included:

  • Epithelium Stroma Classification: Histopathological images from three distinct medical centers (IHC, NKI, VGH).
  • Skin Lesion Classification: A collection of seven public datasets (e.g., HAM10000, MSK) characterized by extreme class imbalances.
  • Spinal Cord Gray Matter Segmentation: MRI data sourced from four healthcare centers.
  • Standard Benchmarks: PACS, OfficeHome, and VLCS were used to verify that the method remains competitive as data scales.

Key Results and Insights

The probabilistic approach consistently outperformed state-of-the-art (SOTA) deterministic methods:

  • Superior Accuracy: On the Epithelium Stroma task, the model achieved 84.06% accuracy, a significant improvement over the previous ~81% SOTA.
  • Robustness in Difficult Domains: In the challenging DMF domain of the skin lesion dataset, the method reached 37.81% accuracy, outperforming the next best model by 2.5%.
  • The Value of Uncertainty: Ablation studies confirmed that the Bayesian layers were the primary driver of success. Removing the probabilistic components led to a sharp decline in performance, proving that uncertainty modeling is vital for small-data generalization.

Conclusion

By integrating global (P-MMD) and local (P-CSA) alignment within a Bayesian framework, this research provides a robust solution for Domain Generalization in data-starved environments. While the use of Monte Carlo sampling introduces some computational overhead, the gains in accuracy and reliability make it a powerful tool for sensitive applications like medical diagnostics. Future work may explore more expressive approximate posteriors, such as normalizing flows, to further refine the latent representations.

Summary updated

BibTeX
@article{chen2024domain,
  author = {Kecheng Chen and Elena Gal and Hong Yan and Haoliang Li},
  title = {{Domain Generalization with Small Data}},
  journal = {Int. J. Comput. Vis.},
  year = {2024},
  doi = {10.1007/s11263-024-02028-4},
}
Figure