Deep neural networks tend to rely on simple features that may be spurious and thus fail to generalize. We study this problem in the setting of linear probes, where a (generalized) linear model is fitted on the representations of a (pretrained) model. We use the connection of these models to the max-margin classifier, and show they favor directions associated with large eigenvalues of the covariance matrix. Whitening removes this preference by equalizing the eigenvalues of the covariance matrix. This observation motivates whitening as a preprocessing step that can reduce reliance on spurious correlations without requiring prior knowledge of their presence or labeled data. We examine the effect of whitening on a synthetic data-generating process and standard spurious correlation benchmarks, and find that it improves robustness. We also find that whitening can improve robustness when added to existing approaches.
Figures & tables
Figure 1: Predictions for ERM (left) and ERM after whitening (right) for d=2000 , plotted against the core coordinate xc and spurious coordinate xs , for 1000 sampled data points. Colors show predictions using all d coordinates, and marker shapes show true classes. Background colors show the probability of predicting class 1 , averaged over the simulations, based on xc and xs .
Figure 2: OOD test accuracy as a function of the noise-to-sample ratio q/n for n=1000 . We compare ERM with three preprocessing choices: no preprocessing, standardization, and whitening, in terms of overall accuracy (left) and worst-group accuracy (right), where groups are defined by the pair (y,a) . Points represent means over 100 simulations, shaded bands are 95% confidence intervals.
Figure 3: Worst-group (left) and equal-group (right) test accuracy for ERM with three preprocessing choices: no preprocessing, standardization, and whitening (top), together with mean within-seed paired differences for whitening minus each reference (bottom). Bars and points represent averages across seeds (ten for ResNet-50, five for BERT), and error bars are 95% confidence intervals.
Figure 4: Variance explained by the top k eigenvalues, up to k=500 (left), and the (normalized) Rayleigh quotient for different classifiers (right). We take the classifier w after ERM with different preprocessing procedures and convert the classifier to the original coordinates, before calculating the Rayleigh quotient. Points and bars represent the average across seeds (ten for ResNet-50 and five for BERT), and error bars the 95% confidence intervals.
Figure 5: Worst-group test accuracy for DFR, AFR and NT for three preprocessing variants: no preprocessing, standardization, and whitening (top), together with mean within-seed paired differences for whitening minus each reference (bottom). Bars and points represent averages across seeds (ten for ResNet-50, five for BERT), and error bars are 95% confidence intervals.
Figure 6: Normalized Rayleigh quotient for Deep Feature Reweighting (DFR), Automatic Feature Reweighting (AFR) and NeuronTune (NT) for three preprocessing variants: no preprocessing, standardization, and whitening. Points and bars represent the average across seeds (ten for ResNet-50 and five for BERT), and error bars are 95% confidence intervals.
Appendix figures & tables7 assets
Supplementary material from the paper’s appendix.
Appendix
Figure 7: Estimated core coefficient w^c (left), spurious coefficient w^s (center), and normalized squared noise-coefficient norm ∥w^ϵ∥22/n (right) as functions of the training sample size n for q/n=1.2 . Solid black curves are simulation averages, vertical error bars are 95% confidence intervals, and dashed lines are the corresponding limits in Theorem 1 .
Figure 8: Fitted core coefficient w^c (left), spurious coefficient w^s (center), and normalized squared noise-coefficient norm ∥w^ϵ∥22/n (right) as functions of the training sample size n for q/n=0.8 . For each simulated sample, logistic regression is fitted after uncentered empirical whitening and the original-coordinate coefficients are normalized to unit minimum training margin. Solid black curves are simulation averages, vertical error bars are 95% confidence intervals, and dashed lines are the exact core-only values from Proposition 1 .
Figure 10: OOD test accuracy as a function of the noise-to-sample ratio q/n for n=1000 . We compare ERM with ERM after empirical whitening in terms of overall accuracy (left) and worst-group accuracy (right), where groups are defined by the pair (y,a) . Points are means over 100 simulations, shaded bands are 95% confidence intervals, and the dotted line marks q/n=1 .
Figure 11: Worst-group (left) and equal-group (right) test accuracy for ERM with empirical whitening and whitening with the nonlinear shrinkage estimator (top), together with mean within-seed paired differences for whitening with the nonlinear shrinkage estimator minus empirical whitening (bottom). Bars and points represent averages across seeds (ten for ResNet-50, five for BERT), and error bars are 95% confidence intervals.
Figure 12: Worst-group (left) and equal-group (right) test accuracy for DINO ViT-B/16 on Waterbirds and CelebA and DeBERTa-v3-base on MultiNLI under three preprocessing variants: no preprocessing, standardization, and whitening (top), together with mean within-seed paired differences for whitening minus each reference (bottom). Bars and points represent averages across three seeds, and error bars are 95% confidence intervals.
Figure 13: Equal-group test accuracy for Deep Feature Reweighting (DFR), Automatic Feature Reweighting (AFR), and NeuronTune (NT) under three preprocessing variants: no preprocessing, standardization, and whitening (top), together with mean within-seed paired differences for whitening minus no preprocessing and whitening minus standardization (bottom). Bars and points show averages across seeds (ten for ResNet-50, five for BERT), and error bars show 95% confidence intervals.
Table 1: Training and validation split sizes for Waterbirds, CelebA, and MultiNLI. The table reports total observations and counts by class y and group g . For Waterbirds and CelebA, groups are indexed by g=2y+a+1 , where a is the binary spurious attribute. For MultiNLI, groups are indexed by g=2y+a .
Frozen pretrained features are often treated as a safe interface for downstream learning: only a small linear readout is trained, while the backbone is fixed. We show that this readout can still overfit noisy labels in a structured way. A label-blind PCA rank sweep reveals a sharp spectral pattern: under label noise, exposing all pretrained directions can hurt clean accuracy, and intermediate ranks often recover much of the lost performance. Rank-matched random projections help less, and measured between-class signal is strongly concentrated in leading PCs. The pattern appears across three ImageNet-pretrained backbones on CIFAR-10, with gains up to 36.0±0.8 points over the default full-rank probe at 40% noise. Tuned full-rank probes outperform validation-selected PCA probes, so we present the sweep as a diagnostic of spectral overfitting rather than a competitive noisy-label method.
Zice Wang, Zhenyu Zhang
School of Future Technology, Northeastern University, Shenyang, China.
Linear probes are widely used in interpretability research and often compared by cosine similarity. The Mahalanobis cosine similarity (MCS) between two directions, which reweights the inner product by test data covariance, is a natural task-aware refinement. Ying et al. (2026) report that a probe's MCS to a reference probe trained on the out-of-distribution (OOD) data near-perfectly linearly predicts the probe's OOD AUROC (R^2 = 0.98). Here, we extend this empirical finding across models, layers, and concept domains, and prove this general phenomenon in closed form: For balanced classes whose projections are Gaussian, OOD AUROC and MCS to the reference probe are linear because both are sigmoid-shaped functions of the probe's signal-to-noise ratio (SNR) on the test data. The theory also predicts when this linearity fails, which we verify empirically. MCS offers a theoretically grounded and empirically effective alternative to Euclidean cosine similarity for comparing linear probes.
Zhuofan Josh Ying, Peter Hase, Nikolaus Kriegeskorte
Departments of 1Psychology, 2Neuroscience, 3Electrical Engineering · 4Zuckerman Mind Brain Behavior Institute; Columbia University, New York, NY · 5Stanford University, Stanford, CA +1
Real-world datasets often contain spurious correlations that are not causally related to the target label. When such correlations dominate the majority of training samples, models tend to rely on them, leading to misclassification of minority samples that do not exhibit the same spurious patterns. While a potential approach is to select subsets of data to better represent the minority samples, this may require access to group labels, which are typically unknown. Furthermore, as we demonstrate, widely used sample scoring functions in the invariant subset or coreset selection literature largely depend on spurious features and therefore fail to accurately capture the importance or difficulty of core, causally relevant features. Accordingly, we propose to mitigate spurious correlations by developing a two-stage sample scoring function that disentangles the learning dynamics of core and spurious features and evaluates their difficulty separately. Based on our proposed metric, we introduce a new algorithm to find and prioritize informative samples both with and without spurious correlations. Extensive experiments demonstrate that a standard ERM model trained on our selected samples achieves superior performance compared to state-of-the-art debiasing techniques, while requiring as little as 10% of the original training data.
Arda Fazla, Abolfazl Hashemi
School of Electrical and Computer Engineering, Purdue University, West Lafayette, IN 47907, USA.