Source-linked AI summary

Fast Model Debias with Machine Unlearning

Ruizhe Chen, Jianfei Yang, Huimin Xiong, Jianhong Bai, Tianxiang Hu, Jin Hao, Yang Feng, Joey Tianyi Zhou, Jian Wu, Zuozhu Liu

arXiv:2310.12560v3cs.LG

TL;DR

Existing debiasing can be costly and may not explain how training samples contribute to model bias. FMD uses counterfactuals and influence functions to identify, evaluate, and unlearn bias; experiments report competing accuracies alongside lower bias and debiasing costs. Its reported approach uses a small external dataset and updates few parameters.

  • Problem

    Existing methods can require costly bias labeling or retraining, and prior work offers limited analysis of how training samples contribute to model bias.

    Source: §3.1 · p. 4
  • Method

    FMD identifies bias from counterfactual predictions, estimates training-sample effects with influence functions, and removes bias through machine unlearning.

    Source: §1 · p. 3
  • Results

    Across multiple datasets, FMD achieves competing accuracies with significantly smaller biases and lower data and computational costs.

    Source: §1 · p. 3, §5 · p. 10
  • Takeaways & Limitations

    FMD uses a small external dataset and updates only a minimal number of model parameters, without requiring access to extensive or unavailable training data.

    Source: §1 · p. 2

    FMD is not applicable to black-box models and requires counterfactual pairs with labeled sensitive attributes, which many datasets lack in sufficient quantity.

    Source: §5 · p. 10

Abstract

from arXiv · show

Recent discoveries have revealed that deep neural networks might behave in a biased manner in many real-world scenarios. For instance, deep networks trained on a large-scale face recognition dataset CelebA tend to predict blonde hair for females and black hair for males. Such biases not only jeopardize the robustness of models but also perpetuate and amplify social biases, which is especially concerning for automated decision-making processes in healthcare, recruitment, etc., as they could exacerbate unfair economic and social inequalities among different groups. Existing debiasing methods suffer from high costs in bias labeling or model re-training, while also exhibiting a deficiency in terms of elucidating the origins of biases within the model. To this respect, we propose a fast model debiasing framework (FMD) which offers an efficient approach to identify, evaluate and remove biases inherent in trained models. The FMD identifies biased attributes through an explicit counterfactual concept and quantifies the influence of data samples with influence functions. Moreover, we design a machine unlearning-based strategy to efficiently and effectively remove the bias in a trained model with a small counterfactual dataset. Experiments on the Colored MNIST, CelebA, and Adult Income datasets along with experiments with large language models demonstrate that our method achieves superior or competing accuracies compared with state-of-the-art methods while attaining significantly fewer biases and requiring much less debiasing cost. Notably, our method requires only a small external dataset and updating a minimal amount of model parameters, without the requirement of access to training data that may be too large or unavailable in practice.

1 Introduction

The introduction motivates debiasing by the robustness and social harms of learned error correlations, then presents FMD as a way to identify, evaluate, and remove bias without costly retraining or extensive bias labeling. Experiments are reported to achieve competing accuracies with smaller biases and lower data and computational costs.

1 Introduction

  • Learned error correlations can undermine robustness and perpetuate social bias, including in crime prediction, loan assessment, and recruitment.The introduction illustrates such correlations with hair-color and gender associations in CelebA.Source: §1 · p. 1
  • Existing debiasing approaches can require expensive bias labeling or computationally intensive retraining, while post-processing may trade accuracy against fairness to individuals.Many methods also assume the biased attributes are already known.Source: §1 · p. 2
  • The framework uses a small external dataset, avoids access to extensive or unavailable training data, and updates only a minimal number of model parameters.The introduction gives top MLP layers of pretrained deep networks as an example.Source: §1 · pp. 2–3
  • FMD identifies bias using counterfactual predictions, evaluates training-sample influence with an extended influence function, and removes learned correlations through unlearning.The removal strategy includes a Newton step and an alternative using a small counterfactual external dataset.Source: §1 · pp. 2–3
  • Experiments on multiple datasets show competing accuracies with significantly smaller biases and lower data and computational costs.FMD also reports consistently improved fairness across diverse bias metrics compared with post-processing methods.Source: §1 · pp. 2–3

2 Related Works

Related work covers fairness metrics, bias mitigation strategies, and machine unlearning. It identifies limits in explaining attribute-driven unfairness, balancing accuracy and fairness, and removing training-sample influence without retraining.

2.1 Group, Individual and Counterfactual Fairness

  • Group and individual fairness metrics capture different notions of fairness, while prediction-focused metrics may not explain how sensitive attributes contribute to unfairness.Counterfactual fairness models causal relations between protected attributes and predictions to explain individual-level bias.Source: §2.1 · p. 3

2.2 Bias Mitigation

  • Pre- and in-processing methods modify data or features, whereas post-processing adjusts outputs; changing selected predictions can create an accuracy–fairness trade-off for individuals.Examples include decision flipping and group-specific thresholds.Source: §2.2 · p. 3

2.3 Machine Unlearning

  • Machine unlearning removes a sample’s influence from a trained model without retraining from scratch, and influence functions support approximate unlearning.The paper extends this paradigm to remove model bias from deep networks.Source: §2.3 · p. 3

3 Method

FMD identifies counterfactual bias, estimates how training samples contribute to it, and removes bias through machine unlearning. The method also extends to group-fairness measures and deep models, with approximations for influence computation.

3.1 Overview and Preliminaries

  • FMD frames model bias as a protected attribute being wrongly correlated with predictions and motivates explicit identification, training-sample evaluation, and removal.Its counterfactual-fairness framing asks whether changing the attribute while holding other attributes fixed changes the output distribution.Source: §3.1 · p. 4

3.2 Bias Identification and Biased-Effect Evaluation

  • Counterfactual pairs vary the attribute while holding other features fixed; their prediction differences identify bias, which is summarized across the external dataset and compared with threshold δ.The external dataset can be constructed from the test set.Source: §3.2 · pp. 4–5
  • A modified influence function estimates each training sample’s contribution to bias; removing a sample that increases bias marks it helpful, and otherwise harmful.The evaluation assumes a twice-differentiable, strictly convex empirical risk for the influence approximation.Source: §3.2 · p. 5

3.3 Bias Removal via Machine Unlearning

  • FMD ranks harmful samples and unlearns the top K with a Newton update, pairing harmful samples with bias-conflicting counterfactuals to mitigate their influence.When training data are too large or unavailable, external counterfactual pairs provide an alternative unlearning approximation.Source: §3.3 · pp. 5–6

3.4 Model Generalization

  • FMD generalizes its bias function to demographic parity and equal opportunity, and approximates influence for deep networks with local optima, applying unlearning to a linear classifier or top MLP layers.The fairness extensions compare protected subgroups; equal opportunity considers the subgroup with A = 1 and Y = 1.Source: §3.4 · p. 6
  • Implicit Hessian-vector products approximate influence, while precomputing and fixing the inverse Hessian during unlearning avoids O(d^3) inversion at every step.The appendix also analyzes continuously updating the inverse Hessian.Source: §3.4 · p. 6

4 Experiment

Experiments evaluate FMD on Colored MNIST, CelebA, Adult Income, and language-model bias, using counterfactual samples and a logistic-regression sanity check. Across the deep-model datasets, FMD reports competitive accuracy with lower bias on Colored MNIST, the best accuracy and bias among debiasing methods on Adult, and the best unbiased and worst-group accuracy on CelebA.

4.1 Experiment details

  • The experiments cover Colored MNIST, CelebA, Adult Income, and StereoSet, with deep-model and language-model debiasing baselines.The language-model comparison uses BERT and GPT-2; unlearning freezes all layers except the last classifier layer.Source: §4.1 · p. 7, Table 4 · p. 9
  • Counterfactual pairs vary color for Colored MNIST, flip the protected attribute for Adult, and match CelebA images by target label and similarity.The CelebA counterfactuals are approximate because gender is not independent of other facial features; Crows-Pairs supplies language-model pairs.Source: §4.1 · p. 7, Figure 2 · p. 7

4.2 Sanity Check on Logistic Regression with a Toy Dataset

  • On the toy logistic-regression task, 50 unlearning samples improved accuracy by 25.71% and reduced counterfactual bias by 0.2755.The most helpful samples were bias-conflicting, while harmful samples were bias-aligned.Source: §4.2 · p. 8, Figure 3 · p. 8

4.3 Experiment on Deep Models

  • On Colored MNIST, accuracy remained competitive with retraining while bias was lower; on Adult, FMD led debiasing methods in accuracy and bias; on CelebA, it led in unbiased and worst-group accuracy.CelebA results also show feasibility with approximate counterfactual pairs.Source: Table 1 · p. 8, §4.3 · pp. 8–9, Table 2 · p. 8

4.4 Analysis

  • On Colored MNIST, counterfactual-based unlearning was effective across counterfactual, demographic-parity, and equal-opportunity bias metrics.It outperformed the other two approaches on accuracy, counterfactual bias, and demographic-parity bias, and was comparable on equal-opportunity bias.Source: §4.4 · p. 9, Table 5 · p. 9
  • Unlearning harmful training samples achieved higher accuracy and less bias than external-pair unlearning, while replacing them with helpful samples excelled on both metrics.Training-sample unlearning takes more time and may be impractical when those samples are unavailable; external pairs provide a satisfactory alternative.Source: §4.4 · pp. 9–10, Table 6 · p. 9
  • On Adult, FMD outperformed logistic-regression post-processing methods in most cases and improved fairness across measures, unlike methods that could worsen other measures.The compared post-processing methods were Equalized Odds, Calibrated Equalized Odds, and Reject Option Classification.Source: §4.4 · p. 10, Table 7 · p. 10
  • On Colored MNIST, accuracy rose and bias fell with more samples before stabilizing beyond 5,000, while unlearning time increased linearly; updating multiple layers took longer.Accuracy improved with two fine-tuned MLP layers but decreased with three; the authors note that the last layer alone can achieve competitive or superior performance.Source: §4.4 · p. 10, Figure 4 · p. 10, Table 8 · p. 10

5 Conclusion and Limitation

The framework achieves superior or competing accuracy with lower bias and computational cost. Its scope is limited by black-box models and the need for labeled sensitive attributes to generate counterfactual pairs.

5 Conclusion and Limitation

  • Experiments show superior or competing accuracy with significantly lower bias and computational cost.Source: §5 · p. 10
  • The method is not applicable to black-box models, which are of interest in real-world scenarios.Source: §5 · p. 10
  • The method requires labeled sensitive attributes to generate counterfactual pairs, while many datasets lack enough such labels.Source: §5 · p. 10
  • The application to large language models and broader fairness analyses are preliminary and left for future work.Source: §5 · p. 10
Loading 2310.12560v3…