Abstract
By inferring latent groups in the training data, recent works introduce invariant learning to the case where environment annotations are unavailable. Typically, learning group invariance under a majority/minority split is empirically shown to be effective in improving out-of-distribution generalization on many datasets. However, theoretical guarantee for these methods on learning invariant mechanisms is lacking. In this paper, we reveal the insufficiency of existing group invariant learning methods in preventing classifiers from depending on spurious correlations in the training set. Specifically, we propose two criteria on judging such sufficiency. Theoretically and empirically, we show that existing methods can violate both criteria and thus fail in generalizing to spurious correlation shifts. Motivated by this, we design a new group invariant learning method, which constructs groups with statistical independence tests, and reweights samples by group label proportion to meet the criteria. Experiments on both synthetic and real data demonstrate that the new method significantly outperforms existing group invariant learning methods in generalizing to spurious correlation shifts.
Introduction
Machine learning models frequently rely on "shortcuts"—spurious correlations between non-causal features and labels—that fail to hold when the data distribution shifts. A classic example is a model identifying a "cow" based on a background of green grass; when presented with a cow on a beach, the model fails.
Invariant Learning (IL) seeks to address this by identifying features that remain consistent across different environments. However, real-world datasets rarely include environment labels. Group Invariant Learning (group-IL) attempts to solve this by automatically inferring these environments. While methods like Environment Invariant Induction (EIIL) have shown promise, they often struggle when spurious correlations are complex or multivariate. This paper investigates the theoretical underpinnings of group-IL and introduces two necessary criteria for its success.
The Limitations of Existing Group-IL
Most current group-IL methods rely on a simple binary split of the data into "majority" and "minority" groups. The authors demonstrate that this approach is often insufficient. When spurious features are multivariate, a simple split may fail to provide enough variance for the model to recognize that a feature is unreliable. If the shortcut remains predictive across all inferred groups, the model will continue to rely on it, failing to achieve true invariance.
Theoretical Criteria for Robustness
To ensure that a group-IL method can successfully ignore spurious correlations, the authors propose two essential criteria:
- Falsity Exposure: The inferred groups must be constructed such that the spurious feature's unreliability is exposed. If the correlation between the spurious feature and the label is identical across all groups, the model has no mathematical incentive to discard the feature. The groups must "break" the shortcut.
- Label Balance: The distribution of labels must be consistent across the inferred groups. If one group is predominantly one class (e.g., 90% "cat") and another group is the opposite, the model may inadvertently use the group identity itself as a new spurious feature, bypassing the goal of learning invariant causal mechanisms.
The SCILL Framework
To satisfy these criteria, the authors introduce SCILL (Spurious-Correlation-strata Invariant Learning with Label-balancing). The method consists of three primary stages:
- Statistical Splitting: Rather than a binary split, SCILL utilizes a biased "reference model" to identify data points where the model is likely relying on shortcuts. It then uses statistical t-tests to stratify the data into multiple groups where the spurious prediction is independent of the actual label.
- Reweighting: To satisfy the Label Balance criterion, SCILL applies weights to samples during the training process. This ensures that every inferred group maintains a balanced label distribution, preventing the group index from becoming a predictive feature.
- Invariant Objective: The model is then trained using standard invariant penalties—such as Invariant Risk Minimization (IRM) or Risk Extrapolation (REx)—applied to these refined, statistically sound groups.
Experimental Evaluation
The authors evaluated SCILL against standard Empirical Risk Minimization (ERM) and the state-of-the-art EIIL across synthetic and real-world benchmarks.
PC-MNIST (Patched-Colored MNIST)
This synthetic dataset was designed to test multivariate spurious correlations by adding both color and a small corner patch to digits. SCILL achieved a test accuracy of 67.6%, significantly outperforming EIIL (64.0%) and ERM (54.5%).
MNLI-HANS
In this Natural Language Inference task, models are trained on the MNLI dataset (rich in lexical overlap biases) and tested on the HANS dataset (where those biases lead to incorrect predictions). SCILL reached an accuracy of 71.2%, while EIIL achieved 66.8%.
Conclusion and Future Work
The research highlights that the success of group-IL depends less on the specific invariant loss function and more on the quality of the inferred groups. By focusing on Falsity Exposure and Label Balance, SCILL provides a more robust framework for OOD generalization.
While SCILL shows significant improvements, it does rely on a "reference model" to capture initial biases. Future work may explore how to satisfy these criteria in even more complex causal graphs where invariant and spurious features are more deeply entangled.
Summary updated