A Dierentiable Distance Approximation for Fairer Image Classication Nicholas Rosa1 Tom Drummond12 and Mehrtash Harandi1

2025-04-28 0 0 449.51KB 19 页 10玖币
侵权投诉
A Differentiable Distance Approximation for
Fairer Image Classification
Nicholas Rosa1, Tom Drummond1,2, and Mehrtash Harandi1
1Monash University, Australia
2The University of Melbourne, Australia
Abstract. Na¨ıvely trained AI models can be heavily biased. This can
be particularly problematic when the biases involve legally or morally
protected attributes such as ethnic background, age or gender. Existing
solutions to this problem come at the cost of extra computation, unstable
adversarial optimisation or have losses on the feature space structure that
are disconnected from fairness measures and only loosely generalise to
fairness. In this work we propose a differentiable approximation of the
variance of demographics, a metric that can be used to measure the
bias, or unfairness, in an AI model. Our approximation can be optimised
alongside the regular training objective which eliminates the need for
any extra models during training and directly improves the fairness of
the regularised models. We demonstrate that our approach improves the
fairness of AI models in varied task and dataset scenarios, whilst still
maintaining a high level of classification accuracy. Code is available at
https://bitbucket.org/nelliottrosa/base_fairness.
1 Introduction
In recent times, the use of Artificial Intelligence (AI) has permeated many pro-
cesses that are used to make important decisions, such as filtering applicants
for jobs, deciding if an applicant should receive credit and recognizing people
in images [27,15]. Given this, it is essential to ensure that AI-driven models are
not exhibiting behaviour which is morally or legally undesirable. In AI, data is
a collection of attributes, which can either be explicit (e.g. labels) or implicit
(e.g. information from an image). Some of these attributes are referred to as
protected attributes as they should not be used to discriminate (e.g. gender,
race or age). However, it has been shown numerous times that AI models which
are na¨ıvely trained are biased against one or more of these protected attributes,
as they exhibit lower accuracy for some demographics [4,11,19]. This behaviour
is discriminatory against these demographics and is morally or legally undesir-
able, or simply unfair. There are two common sources of unfair behaviour that
can present itself in AI systems. The first source is biases that are present in
the data used for training AI models. Biases in the data with respect to pro-
tected attributes can cause an AI model trained upon that data to discriminate
against the protected attribute [2]. For example, if a dataset used to train a
facial recognition model for unlocking doors, only contains images of men (i.e.
arXiv:2210.04369v1 [cs.CV] 9 Oct 2022
2 N. Rosa et al.
bias with respect to gender) then the learned model will not accurately recognise
and admit women (i.e. unfair behaviour). The second source of bias is due to
some values or demographics of a protected attribute being inherently harder
for AI to recognize than others. For example, it has been shown that even when
training with a balanced dataset, faces with a darker skin tone are harder to
recognize for facial recognition algorithms [30].
Various solutions to the fairness problem have been proposed. We focus on
algorithmic in-processing methods for reducing the bias[9,36,6,31,8,10,5,14]. In-
processing aims to address the bias of a model by applying an extra objective
during training which makes the model bias-aware and consequentially learns a
fairer model. In-processing has proven to be quite effective at reducing the un-
fair behaviour of AI. However, in-processing methods often include extra models
which can increase training cost and complexity [16]; use adversarial training
[9,36,8,6] which has proven to be notoriously unstable [26] or make assump-
tions about the representation space of the model which may not hold in all
cases[10,23,35]. Creating fair AI models is particularly difficult in the computer
vision domain as any problems with extra computational cost and complexity
are exacerbated by the large models utilized. Additionally the high dimensional-
ity of images means they can contain many implicit attributes, which are often
highly correlated to each other and to protected attributes. Disentangling the
implicit factors is extra challenging in these cases.
In this paper, we introduce Bias Accuracy Standard deviation Estimation or
BASE, a novel fairness algorithm, which optimizes a differentiable approxima-
tion of the fairness metric standard deviation of accuracy across demographics
(σacc) to learn an AI model which is fair with respect to equalized odds (EO).
Models that exhibit a low standard deviation of accuracy across demographics
or variance of demographics have the property of equal performance on a target
task regardless of the demographic of the protected attribute. For example, a
facial recognition model which has low variance of demographics for ethnicity,
is equally likely to correctly recognize the identity of a person from an image
regardless of their ethnicity. Reducing the variance of demographics of a model
makes it fairer w.r.t. EO. However, for an AI model that is trained with gradient
based optimization the variance of demographics is difficult to use. This is due to
the accuracy of a single sample - an integral part of the variance of demograph-
ics (Section 2.3) - having an undefined gradient at 0 and being 0 everywhere
else, which leads to zero influence on the model parameters. BASE overcomes
this difficulty by instead using a sigmoid based approximation of accuracy which
we call soft-accuracy inside the variance of demographics metric. This approach
has multiple advantages. Firstly computational efficiency, for example, training
a classifier on images with BASE incurs only the extra computation of calcu-
lating the variance of demographics. Compare this to training a classifier with
knowledge distillation [16] or adversarial debiasing [36], where additional models
are used which incur extra memory usage for the model parameters and gradi-
ents, alongside with extra computation for the forward pass of the additional
model. Secondly, BASE makes no assumptions about the representation space.
A Differentiable Distance Approximation for Fairer Image Classification 3
The model will automatically learn the representation space structure required
to reduce the variance of demographics. Furthermore, due to its simplicity BASE
can be combined with other solutions.
To summarize the main contributions of our work are:
Provide a novel method for improving the fairness on AI models trained with
gradient based optimization, that increases algorithmic simplicity and does
not rely on training additional models (Section 3.1).
Show that our method is competitive with and in some cases outperforms
current state-of-the-art fair image classifiers when using either a biased
dataset or an unbiased dataset (Section 4.4, Section 4.4).
Show that our method increasingly outperforms the fairness of a naive clas-
sifier when exposed to increasingly biased training sets in which target and
protected attributes are strongly correlated. Our method also achieves higher
over-all accuracy on heavily biased datasets (Section 4.4).
2 Related Work and Preliminaries
Fair AI has received increasing attention in the past few years and a varied range
of solutions has been proposed. Algorithmic methods for reducing the bias can
be broken down into three main categories based upon when they apply their
fairness constraint. Pre-processing methods aim to change the distribution of
the data used for training such that a fairer model is produced. These methods
include re-sampling, which changes the sampling rate of data during training
to ensure each protected class is equally represented [1,25,28] and augmentation
methods which add synthetic data to the dataset [24,34,3,37] to balance the
protected classes. The second class of methods, post -processing methods, aim to
adjust the prediction after the fact to compensate for the bias [32]. Pre-processing
and post-processing have some major drawbacks. Pre-processing only addresses
the bias in the dataset and the inherent difficulties of some demographics can
still cause a biased model [31,30]. On the other hand post-processing methods
require that protected attribute labels to be known at inference time or assume
that the target and protected attribute are independent [32]. Our method is
related to the final category of in-processing, which is discussed further below.
In-processing methods typically run under a constrained optimization scheme
where a loss penalty or a special construction of the AI model is used to reduce
the bias during optimization.
2.1 In-processing for Fair Classification
Like many machine learning tasks, the fairness problem is difficult to optimize
directly and adversarial training became a common method to create fair repre-
sentations and predictors [9,36,6,31,8]. These methods use an adversarial model,
or adversary, whose purpose is to learn the relationship between the predictor
and the protected attribute. The output of the adversary is then used to enforce a
4 N. Rosa et al.
fairness constraint upon the predictor. This is achieved either by gradient rever-
sal of the adversary or by maximising the entropy of the adversaries predictions.
If a strong adversary is unable to determine a relationship between the predictor
and the protected attribute then fairness of the predictor can be guaranteed [36]
Other constrained optimization methods have been proposed and their ap-
proaches vary greatly. Gong et al. [10] minimize the variance of sample density
across different demographics within the representation space. Cho et al. [5]
use a kernel density estimate to approximate the conditional distributions used
for measuring fairness in a differentiable manner. Hwang et al. [14] reduce the
Wasserstein distance between protected groups within the representation space.
Finally, in a work most similar to our own Shen et al. [29] use cross-entropy loss
as a proxy for probability during training to optimise for fairness. Our method
differs in two main aspects; our objective directly considers the two elements of
the models output vector responsible for determining accuracy and we evaluate
our work in the computer vision domain.
2.2 Problem definition
The ultimate goal of fair machine learning is to create predictors which con-
tain no bias. There is, however, many different forms of bias that can present
themselves and as a consequence there are multiple different definitions of fair-
ness. The three most common definitions are Demographic parity [36], Equalized
Odds [12] and Equalized Opportunity [12]. In the following section A,ˆ
Yand Y
are random variables which represent the protected attribute, the output of a
predictor and the true value of the target attribute respectively.
Demographic Parity Demographic parity is the simplest form of fairness since
it only considers the output of the predictor and the protected attribute. A pre-
dictor satisfies demographic parity when its output is independent of the pro-
tected attribute. That is a∈ A; Pr( ˆ
Y= ˆy|A=a) = Pr( ˆ
Y= ˆy). However, this
definition does not always allow for perfect classification [12]. If there is any cor-
relation between the protected attribute and the target task then maintaining
independence forces a reduction in performance. For example, if we learned a pre-
dictor for university admittance with age as a protected attribute, then achieving
demographic parity would require our predictor to admit young children with
the same probability as those who had just finished high school, regardless of
each individuals suitability.
Equalized Odds Equalized Odds is another definition of fairness that is more
commonly applied for computer vision tasks. A predictor satisfies equalized odds
when its output is conditionally independent of the protected attribute for all
classes of the target class. That is y∈ Y,a, a0∈ A,Pr( ˆ
Y=y|A=a, Y =y) =
Pr( ˆ
Y=y|A=a0, Y =y). This definition allows us to maintain performance
as it is satisfied when a predictor achieves the same level of accuracy for each
demographic of the protected attribute.
摘要:

ADi erentiableDistanceApproximationforFairerImageClassi cationNicholasRosa1,TomDrummond1;2,andMehrtashHarandi11MonashUniversity,Australia2TheUniversityofMelbourne,AustraliaAbstract.NavelytrainedAImodelscanbeheavilybiased.Thiscanbeparticularlyproblematicwhenthebiasesinvolvelegallyormorallyprotected...

展开>> 收起<<
A Dierentiable Distance Approximation for Fairer Image Classication Nicholas Rosa1 Tom Drummond12 and Mehrtash Harandi1.pdf

共19页,预览4页

还剩页未读, 继续阅读

声明:本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。玖贝云文库仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知玖贝云文库,我们立即给予删除!
分类:图书资源 价格:10玖币 属性:19 页 大小:449.51KB 格式:PDF 时间:2025-04-28

开通VIP享超值会员特权

  • 多端同步记录
  • 高速下载文档
  • 免费文档工具
  • 分享文档赚钱
  • 每日登录抽奖
  • 优质衍生服务
/ 19
客服
关注