Enhancing Evolving Domain Generalization through Dynamic Latent Representations

Binghui Xie, Yongqiang Chen, Jiaqi Wang, Kaiwen Zhou, Bo Han, Wei Meng, James Cheng

Introduction

In traditional machine learning, we often assume that training and testing data come from the same distribution. However, in real-world applications, data distributions frequently drift over time—a phenomenon known as non-stationarity. For instance, a model trained on financial data from the early 2000s might fail to predict market trends in 2024 because consumer behavior and economic policies have evolved. This challenge is the focus of Evolving Domain Generalization (EDG).

Unlike standard Domain Generalization (DG), which seeks features that are strictly invariant across discrete environments, EDG recognizes that domains often follow a continuous, structured trajectory (e.g., time or location). The core difficulty lies in the fact that while some features remain constant, others change predictably. Relying solely on invariant features—the standard approach in DG—ignores the valuable information contained within these evolving dynamics.

Figure 1: The Portraits dataset illustrates Evolving Domain Generalization, where fashion and hairstyles change continuously from 1905 to 2013 while facial structures remain relatively invariant.

The MISTS Framework

To address the limitations of existing methods, this paper introduces MISTS (Mutual Information-Based Sequential Autoencoders). MISTS is designed to disentangle invariant features from dynamic ones, leveraging both to improve predictive performance on future, unseen domains.

1. Causal Foundation

The authors utilize Structural Causal Models (SCMs) to formalize the EDG problem. They provide a theoretical proof demonstrating that a classifier incorporating both invariant latent variables ($z_c$) and time-evolving dynamic variables ($z_t$) will consistently achieve lower risk than a model restricted to invariant features alone. This highlights the necessity of capturing the "drift" rather than just ignoring it.

2. Disentangled Sequential Architecture

The MISTS architecture employs a dual-stream encoding process. An input sequence $x_{1:T}$ is processed by a shared encoder, after which two separate Long Short-Term Memory (LSTM) networks extract distinct representations:

  • Invariant Stream: Learns a global representation $z_c$ that captures characteristics shared across all observed time steps.
  • Dynamic Stream: Tracks the evolution of features $z_t$ over time, modeling the trajectory of the distribution shift.
Figure 3: The MISTS architecture uses dual LSTMs and a Mutual Information (MI) constraint to disentangle invariant ($z_c$) and dynamic ($z_{1:T}$) latent representations for robust prediction.

3. Information-Theoretic Constraints

A critical challenge in learning two types of representations is preventing "leakage," where the dynamic encoder inadvertently captures static information or vice versa. MISTS solves this by minimizing the Mutual Information (MI) between $z_c$ and $z_t$. By enforcing this independence, the model ensures that the two latent spaces are mutually exclusive and capture complementary information.

4. Domain-Adaptive Classifier

Rather than using a fixed linear head, MISTS features a classifier that adapts to the temporal context. By conditioning the classification on the sequence of dynamic latents, the model can "anticipate" the state of the next domain, leading to more accurate predictions in the future.

Experimental Evaluation

The researchers benchmarked MISTS against several baselines, including Empirical Risk Minimization (ERM) and Latent Space Sequential Autoencoders (LSSAE), across seven diverse datasets.

Datasets

  • Synthetic Benchmarks: Circle, Sine, and Sine-C provide controlled environments to test how models handle oscillating patterns and sudden label reversals. Rotated MNIST tests robustness to continuous geometric transformations.
  • Real-World Benchmarks:
    • Portraits: High school yearbook photos spanning over a century (1905–2013).
  • Caltran: Real-world traffic surveillance data.
  • Elec: Italian electricity market records influenced by seasonal and economic shifts.

Results and Insights

MISTS consistently outperformed state-of-the-art methods, achieving an average accuracy of 69.9% across all tasks, compared to 67.0% for LSSAE and 62.3% for ERM. Qualitative analysis on the Sine dataset revealed that MISTS is uniquely capable of tracking complex decision boundaries even at timestamps not seen during training.

Ablation studies further underscored the importance of the MI constraint. Without it, the model's ability to generalize to future domains significantly degraded, proving that the clean separation of invariant and dynamic features is essential for handling non-stationary data.

Conclusion and Future Directions

MISTS represents a significant step forward in Evolving Domain Generalization by proving that "dynamics matter." By explicitly modeling and disentangling the way data changes over time, MISTS provides a more robust framework for real-world deployment where environments are rarely static.

Future research will focus on automating the balance between invariant and dynamic features, as the optimal ratio often depends on the specific task. Additionally, exploring how these models handle "abrupt" changes—sudden, non-continuous changes—remains a vital area for exploration.

Summary updated

BibTeX
@inproceedings{xie2024enhancing,
  author = {Binghui Xie and Yongqiang Chen and Jiaqi Wang and Kaiwen Zhou and Bo Han and Wei Meng and James Cheng},
  title = {{Enhancing Evolving Domain Generalization through Dynamic Latent Representations}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2024},
  doi = {10.1609/aaai.v38i14.29536},
}
Figure