Gradient-Guided Annealing for Domain Generalization

Aristotelis Ballas, Christos Diou
2/10/2026

No official code found. Best implementation: aristotelisballas/GGA (18 stars, MIT, last commit 2025-07-22).

Abstract

Domain Generalization (DG) research has gained considerable traction as of late, since the ability to generalize to unseen data distributions is a requirement that eludes even state-of-the-art training algorithms. In this paper we observe that the initial iterations of model training play a key role in domain generalization effectiveness, since the loss landscape may be significantly different across the training and test distributions, contrary to the case of i.i.d. data. Conflicts between gradients of the loss components of each domain lead the optimization procedure to undesirable local minima that do not capture the domain-invariant features of the target classes. We propose alleviating domain conflicts in model optimization, by iteratively annealing the parameters of a model in the early stages of training and searching for points where gradients align between domains. By discovering a set of parameter values where gradients are updated towards the same direction for each data distribution present in the training set, the proposed Gradient-Guided Annealing (GGA) algorithm encourages models to seek out minima that exhibit improved robustness against domain shifts. The efficacy of GGA is evaluated on five widely accepted and challenging image classification domain generalization benchmarks, where its use alone is able to establish highly competitive or even state-of-the-art performance. Moreover, when combined with previously proposed domain-generalization algorithms it is able to consistently improve their effectiveness by significant margins1.

View on arXivView PDF

Code Implementations(1)

MIT

This is the official code repository for the "Gradient-Guided Annealing for Domain Generalization" (CVPR 2025) paper.

182PythonFeb 25, 20251 years agoMIT

Similar Papers

Cite this paper

@article{ballas2026gradientguided,
  title  = {Gradient-Guided Annealing for Domain Generalization},
  author = {Aristotelis Ballas and Christos Diou},
  year   = {2026},
  eprint = {2502.20162},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2502.20162},
  journal = {CVPR 2025 2025}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.20162.svg)](https://codeofpaper.com/paper/2502.20162)

Discussion