English

Evaluating and Mitigating Bias in Image Classifiers: A Causal Perspective Using Counterfactuals

Computer Vision and Pattern Recognition 2022-01-07 v4 Machine Learning

Abstract

Counterfactual examples for an input -- perturbations that change specific features but not others -- have been shown to be useful for evaluating bias of machine learning models, e.g., against specific demographic groups. However, generating counterfactual examples for images is non-trivial due to the underlying causal structure on the various features of an image. To be meaningful, generated perturbations need to satisfy constraints implied by the causal model. We present a method for generating counterfactuals by incorporating a structural causal model (SCM) in an improved variant of Adversarially Learned Inference (ALI), that generates counterfactuals in accordance with the causal relationships between attributes of an image. Based on the generated counterfactuals, we show how to explain a pre-trained machine learning classifier, evaluate its bias, and mitigate the bias using a counterfactual regularizer. On the Morpho-MNIST dataset, our method generates counterfactuals comparable in quality to prior work on SCM-based counterfactuals (DeepSCM), while on the more complex CelebA dataset our method outperforms DeepSCM in generating high-quality valid counterfactuals. Moreover, generated counterfactuals are indistinguishable from reconstructed images in a human evaluation experiment and we subsequently use them to evaluate the fairness of a standard classifier trained on CelebA data. We show that the classifier is biased w.r.t. skin and hair color, and how counterfactual regularization can remove those biases.

Keywords

Cite

@article{arxiv.2009.08270,
  title  = {Evaluating and Mitigating Bias in Image Classifiers: A Causal Perspective Using Counterfactuals},
  author = {Saloni Dash and Vineeth N Balasubramanian and Amit Sharma},
  journal= {arXiv preprint arXiv:2009.08270},
  year   = {2022}
}

Comments

Accepted for Publication at WACV 2022

R2 v1 2026-06-23T18:36:50.849Z