Probable Domain Generalization via Quantile Risk Minimization

Cian Eastwood, Alexander Robey, Shashank Singh, Julius von Kügelgen, Hamed Hassani, George J. Pappas, Bernhard Schölkopf

Introduction

Machine learning models often suffer from "distribution shift," where a model trained in one environment (e.g., a specific hospital) fails when deployed in another. The field of Domain Generalization (DG) seeks to build models that remain robust across unseen test domains by training on multiple related environments. Traditionally, researchers choose between Empirical Risk Minimization (ERM), which optimizes for average performance, or Distributionally Robust Optimization (DRO), which focuses on the worst-case scenario. However, ERM often captures spurious correlations, while DRO can be overly conservative, sacrificing general performance for unlikely "nightmare scenarios."

This paper, presented at NeurIPS 2022, introduces Quantile Risk Minimization (QRM), a framework that finds a middle ground by minimizing the $\alpha$-quantile of a model's risk distribution.

Methodology: Probable Domain Generalization

The authors propose treating training and test domains as random draws from an underlying "meta-distribution." By shifting the focus from fixed domains to a probabilistic distribution of domains, they can provide "probable" performance guarantees.

Conceptual framework of Probable Domain Generalization, comparing ERM, EQRM, and DRO strategies.

Quantile Risk Minimization (QRM)

Instead of the mean risk, QRM minimizes the $\alpha$-quantile. For instance, setting $\alpha=0.9$ ensures the best possible performance that holds across 90% of potential domains. To implement this with a finite set of training domains, the authors use Kernel Density Estimation (KDE) to smooth the empirical risk distribution. This smoothing creates a "right tail," allowing the model to perform "risk extrapolation"—estimating performance on domains more challenging than those encountered during training. Mathematically, as $\alpha \to 1$, the model is forced to ignore unstable, spurious features and focus on causal invariances.

Experimental Evaluation

The framework was evaluated on several rigorous benchmarks:

  • Synthetic Linear Regression: To verify causal relationship recovery.
  • ColoredMNIST (CMNIST): A dataset where color acts as a spurious cue.
  • WILDS Benchmark: Including iWildCam (animal identification across camera traps) and OGB-MolPCBA (molecular property prediction).
  • DomainBed: A standard suite of DG datasets including PACS, OfficeHome, and TerraIncognita.

Key Results and Insights

EQRM demonstrates superior performance in the "tails" of the distribution. On the OGB dataset, it reduced worst-case risk by over 50% compared to ERM. In synthetic tests, the model successfully transitioned from capturing spurious "effect" features to locking onto "causal" features as the confidence level $\alpha$ increased.

Empirical results showing causal recovery and tail performance improvements.

The $\alpha$ parameter serves as an interpretable "conservativeness knob." At $\alpha \approx 0.5$, the model behaves like standard ERM; as $\alpha$ approaches 1, it achieves worst-case robustness. This flexibility allows practitioners to tune models based on the safety requirements of their specific application, such as medical imaging or autonomous driving.

Conclusion and Future Work

QRM provides a statistically grounded approach to domain generalization that balances average-case efficiency with worst-case robustness. While the method currently assumes domains are independent and identically distributed (i.i.d.) from a meta-distribution, future work may explore relaxing this assumption to account for temporal or geographic dependencies between domains.

Summary updated

BibTeX
@inproceedings{eastwood2022probable,
  author = {Cian Eastwood and Alexander Robey and Shashank Singh and Julius von Kügelgen and Hamed Hassani and George J. Pappas and Bernhard Schölkopf},
  title = {{Probable Domain Generalization via Quantile Risk Minimization}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2022},
  url = {https://openreview.net/forum?id=4gkNscaiHC},
}
Figure