NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Signal Is Harder To Learn Than Bias: Debiasing with Focal Loss

Moritz Vandenhirtz, Laura Manduchi, Ričards Marcinkevičs, Julia E Vogt

TL;DR

Deep neural networks frequently latch onto spurious correlations—shortcuts that are easy to learn during training but fail to generalize in deployment. Signal is Harder (SiH) leverages this learning dynamic by training a biased classifier to deliberately capture the shortcut, and using a focal-loss-inspired reweighting scheme to train an unbiased classifier without requiring bias labels. Paired with a dual-encoder Variational Autoencoder (VAE), SiH both boosts worst-case test accuracy and visualizes unknown biases through minimal latent adversarial perturbations.

What Problem Does This Paper Address?

When a dataset contains spurious correlations (e.g., waterbirds predominantly appearing against water backgrounds), models tend to exploit the shortcut rather than learning the true underlying signal. While many debiasing techniques assume explicit metadata labeling the spurious attribute, real-world datasets rarely provide such ground truth.

Unsupervised debiasing algorithms like Learning from Failure (LfF) circumvent this by assuming that bias is inherently "easier to learn" than signal. LfF trains a biased model using Generalized Cross Entropy (GCE) to catch the easy examples, and an unbiased model by upweighting the hard, bias-conflicting examples using a Relative Difficulty Score (RDS). However, RDS depends on complex, ad-hoc stabilizing heuristics (such as exponential moving averages and class-wise maximum normalization). Furthermore, existing approaches struggle to cleanly visualize what spurious feature the network actually learned without introducing severe visual artifacts.

Methods

The authors propose Signal is Harder (SiH), combining a dual-encoder VAE with an elegant loss reweighting formulation:

           ┌─► Signal Encoder (Es) ──► zs ──► Unbiased Classifier (Cs) ──► y_s
           │                                │
Input (x) ─┤                                ├──► Concatenate [zs, zb] ──► Decoder (D) ──► x_recon
           │                                │
           └─► Bias Encoder (Eb)   ──► zb ──► Biased Classifier (Cb)   ──► y_b
  1. Architecture: A VAE splits input features into a signal latent $z_s$ and a bias latent $z_b$. The unbiased classifier $C_s$ predicts the label from $z_s$, while the biased classifier $C_b$ predicts it from $z_b$. A shared decoder reconstructs the image from $[z_s, z_b]$.
  2. Biased Classifier Optimization: Trained with Generalized Cross Entropy (GCE) loss ($q = 0.7$), which strongly amplifies samples that are already easy to classify correctly (bias-aligned samples).
  3. Focal Reweighting for the Unbiased Classifier: Instead of using the multi-heuristic RDS, SiH borrows the focal loss mechanism to upweight bias-conflicting samples: $$\frac{\partial \mathcal{L}_s(\hat{y}_s, \hat{y}_b, y)}{\partial \theta_s} = (1 - \hat{y}_b)^q \frac{\partial \text{CE}(\hat{y}_s, y)}{\partial \theta_s}$$ The weighting factor $(1 - \hat{y}_b)^q$ is detached from the gradient graph. When the biased model struggles ($\hat{y}_b$ is small), the sample is treated as bias-conflicting, heavily weighting its cross-entropy gradient for the unbiased classifier.

  4. Bias Visualization via Latent DeepFool: To interpret the bias without dataset swapping artifacts (used in prior work like DisEnt), SiH applies an $\ell_2$-norm DeepFool adversarial perturbation directly to the bias latent $z_b$, pushing $C_b$ toward an incorrect class. Passing the perturbed $z_b$ and untouched $z_s$ through the decoder reveals precisely what visual attribute was treated as bias.

Datasets

  • Colored MNIST: Handwritten digits where digit identity is the signal $z_s$ and synthetically injected foreground color is the bias $z_b$. Tested across bias-conflicting ratios of 0.5%, 1%, 2%, 5%, 10%, and 20%.
  • Corrupted CIFAR-10: CIFAR-10 objects paired spuriously with specific visual corruptions (e.g., fog, brightness, pixelation) across identical bias-conflicting ratios (0.5%–20%).
  • Evaluation: Evaluated on unbiased test sets where signal and bias are independently and uniformly distributed.

Key Insights and Ideas

  • Focal loss replaces heuristic stabilization: The focal term $(1 - \hat{y}_b)^q$ mirrors GCE naturally. It isolates bias-conflicting examples cleanly without the exponential moving averages and batch-level normalizations required by previous RDS formulas.
  • Simultaneous generative training: Training the VAE decoder alongside the classifiers forces the latent space to retain all image-relevant information, supporting signal discovery without requiring a separate post-hoc decoder.
  • Minimal latent perturbations reduce artifacts: Swapping latent vectors between images (as in DisEnt) swaps residual signal attributes if disentanglement is imperfect, causing identity shifts. DeepFool on $z_b$ finds the minimal change required to neutralize the bias classifier, preserving object identity.

Key Results

  • Colored MNIST: Under severe bias (0.5% bias-conflicting ratio), SiH achieves 71.63% unbiased accuracy, significantly outperforming DisEnt (63.98%), LfF (60.42%), and Vanilla ERM (43.70%).
  • Corrupted CIFAR-10: SiH leads at higher bias-conflicting ratios (e.g., 61.26% vs. LfF's 59.29% at 10%), while LfF retains an edge at the lowest ratios (0.5%–2%).
  • Focal Loss vs. RDS Ablation: Replacing RDS with focal loss ($\text{SiH}$ vs. $\text{SiH}_{\text{RDS}}$) boosts accuracy across almost all corruption ratios (e.g., from 64.17% to 71.63% at 0.5% Colored MNIST) and substantially tightens standard deviation across random seeds.
  • Qualitative Interpretability: In Colored MNIST, SiH changes only the digit's color in reconstruction, whereas DisEnt frequently distorts the digit shape.

Limitations and Future Work

  • Disentanglement in complex images: On Corrupted CIFAR-10, the latent space failed to disentangle signal and bias well enough for either SiH or DisEnt to produce clean visualizations.
  • Accuracy-interpretability tradeoff: Reconstructing pixel-level detail via VAE introduces a slight performance tax compared to pure classification backbones.
  • Simpler benchmarks: Tested primarily on synthetically injected corruptions/colors rather than real-world organic dataset biases (e.g., Waterbirds, CelebA).
  • Theoretical foundations: The authors highlight that the field still lacks a rigorous mathematical definition for what makes an attribute "easier to learn" than another, pointing toward diffusion models and GANs as better future generative backbones.

Summary updated

BibTeX
@inproceedings{vandenhirtz2023signal,
  author = {Moritz Vandenhirtz and Laura Manduchi and Ričards Marcinkevičs and Julia E Vogt},
  title = {{Signal Is Harder To Learn Than Bias: Debiasing with Focal Loss}},
  booktitle = {DG @ ICLR},
  year = {2023},
  url = {https://openreview.net/forum?id=PEPSFxkjqg},
}
Figure