Detecting labeling bias using influence functions

Frida Jørgensen, Nina Weng, Siavash A. Bigdeli

This paper, recently published by researchers from Copenhagen University and the Technical University of Denmark, tackles a fundamental "garbage in, garbage out" problem in machine learning: labeling bias.

TL;DR

The authors propose a pipeline using Influence Functions to identify systematically mislabeled training data that can lead to unfair models. By approximating the "impact" of individual training samples on model predictions, they successfully detected nearly 90% of mislabeled samples in MNIST and identified significant bias signals in complex medical imaging data.

What Problem Does This Paper Address?

Most "fairness" techniques in AI focus on the output: they try to ensure a model’s predictions are equal across different demographic groups. However, these methods usually assume that the training labels themselves are a "ground truth" reflection of reality.

In the real world, this assumption often fails. Labeling bias occurs when certain subgroups are systematically mislabeled due to limited resources, annotator prejudice, or cultural misunderstandings. If the training data is fundamentally biased, standard fairness constraints can actually make the model perform worse for the very groups they are meant to protect. The authors ask a critical question: instead of just trying to fix the model's predictions, can we find and fix the "poisoned" data points that caused the bias in the first place?

Methods

The core tool used here is the Influence Function (IF). Conceptually, an influence function asks: "How would the model's parameters change if we slightly increased the weight of this specific training sample?"

To calculate this without retraining the model thousands of times (which would be computationally impossible), the authors use a mathematical shortcut involving the gradient (the direction of the error) and the Hessian (the "curvature" of the error surface) of the loss function.

The Innovation: Scalable Approximations

Calculating the exact inverse Hessian for a modern neural network is a nightmare—it scales quadratically with the number of parameters. To make this work on real-world models, the authors employed two key strategies:

  1. Diagonal Approximation: Instead of the full Hessian matrix, they used only the diagonal elements (via the Laplace toolbox), drastically reducing the math required.
  2. Last-Layer Focus: For complex models like ResNet18, they restricted the influence calculation to the final layer of the network. This treats the earlier layers as a fixed feature extractor and focuses the "audit" on the decision-making head of the model.

Datasets

The team evaluated their pipeline on two distinct benchmarks:

  • MNIST (Handwritten Digits): They created a subset called "MNIST49" (only 4s and 9s). To simulate bias, they flipped 20% of the labels for the digit "9" to "4".
  • CheXpert (Medical Imaging): A large-scale dataset of chest X-rays. They focused on "Pleural Effusion" and flipped 20% of the positive cases to negative to simulate a scenario where a specific condition is systematically under-diagnosed.

Key Insights and Ideas

  • "Harmful" vs. "Helpful" Samples: Influence scores can be positive or negative. A positive score indicates a "harmful" sample that increases the model's loss on a test point. The authors found that mislabeled samples almost always show up as highly "harmful" because they contradict the patterns the model is trying to learn.
  • The Power of Thresholding: In simpler datasets, there is a clear "gap" in influence scores between clean data and mislabeled data. By setting a simple threshold, you can effectively "quarantine" suspicious samples for human review.
  • Debugging the "Black Box": This approach shifts the focus of Explainable AI (XAI) from what the model is looking at (e.g., heatmaps) to who taught the model that behavior (specific training instances).

Key Results

  • MNIST Success: On the digit dataset, the method was remarkably precise. By setting an influence threshold of 0.5, they detected nearly 90% of the mislabeled samples while flagging only 0.4% of the correctly labeled samples as false positives.
  • CheXpert Signal: While the results on medical images were less "clean" than MNIST, mislabeled samples still consistently exhibited higher influence scores than correctly labeled ones. The "flipped" samples appeared much more frequently among the top-10 most harmful points than would be expected by random chance.

Limitations and Future Work

The authors are transparent about the hurdles remaining for this technique:

  • The Complexity Gap: The jump from MNIST to CheXpert showed that as data becomes more complex and "noisy" (like medical X-rays), the separation between "clean" and "biased" influence scores becomes blurrier.
  • Approximation Errors: Using only the last-layer Hessian is a "strong approximation." While it makes the math feasible, it might miss deeper, more structural biases embedded in the earlier layers of a deep network.
  • Future Directions: The authors suggest that future work should explore extending the Hessian computation to more layers and testing different approximation strategies to see if the "signal" in complex datasets can be sharpened.

Ultimately, this work provides a promising roadmap for automated data auditing, moving us closer to AI systems that aren't just fair in their outputs, but are built on fundamentally more honest foundations.

Summary updated

Abstract

Labeling bias arises during data collection due to resource limitations or unconscious bias, leading to unequal label error rates across subgroups or misrepresentation of subgroup prevalence. Most fairness constraints assume training labels reflect the true distribution, rendering them ineffective when labeling bias is present; leaving a challenging question, that \textit{how can we detect such labeling bias?} In this work, we investigate whether influence functions can be used to detect labeling bias. Influence functions estimate how much each training sample affects a model's predictions by leveraging the gradient and Hessian of the loss function -- when labeling errors occur, influence functions can identify wrongly labeled samples in the training set, revealing the underlying failure mode. We develop a sample valuation pipeline and test it first on the MNIST dataset, then scaled to the more complex CheXpert medical imaging dataset. To examine label noise, we introduced controlled errors by flipping 20\% of the labels for one class in the dataset. Using a diagonal Hessian approximation, we demonstrated promising results, successfully detecting nearly 90\% of mislabeled samples in MNIST. On CheXpert, mislabeled samples consistently exhibit higher influence scores. These results highlight the potential of influence functions for identifying label errors.
BibTeX
@misc{jrgensen2026detecting,
  author = {Frida Jørgensen and Nina Weng and Siavash A. Bigdeli},
  title = {{Detecting labeling bias using influence functions}},
  year = {2026},
  eprint = {2602.19130},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2602.19130},
}
Figure