I MPROVING F AIRNESS VIA FEDERATED LEARNING
Anonymous authors
Paper under double-blind review
A BSTRACT
Recently, lots of algorithms have been proposed for learning a fair classiﬁer from centralized data.
However, how to privately train a fair classiﬁer on decentralized data has not been fully studied yet.
In this work, we ﬁrst propose a new theoretical framework, with which we analyze the value of federated learning in improving fairness.
Our analysis reveals that federated learning can strictly boost model fairness compared with all non-federated algorithms.
We then theoretically and empirically show that the performance tradeoff of F ED A VG -based fair learning algorithms is strictly worse than that of a fair classiﬁer trained on centralized data.
To resolve this, we propose F ED FB, a private fair learning algorithm on decentralized data with a modiﬁed F ED A VG protocol.
Our extensive experimental results show that F ED FB signiﬁcantly outperforms existing approaches, sometimes achieving a similar tradeoff as the one trained on centralized data.
I NTRODUCTION
As machine learning is now used to make critical decisions that affect human life, culture, and rights, fair learning has recently received increasing attention.
Various fairness notions have been introduced in the past few years (Dwork et al., 2012; Hardt et al., 2016; Zafar et al., 2017b;a; Kearns et al., 2018; Friedler et al., 2016).
Among various fairness notions, group fairness is the most studied one (Hardt et al., 2016; Zafar et al., 2017a).
Group fairness requires the classiﬁer to treat different groups similarly, where groups are deﬁned with respect to sensitive attributes such as gender and race.
One of the most commonly used group fairness notions is demographic parity , which requires that different groups are equally likely to receive desirable outcomes.
There has been a large amount of work in training fair classiﬁers (Zafar et al., 2017c; Hardt et al., 2016; Roh et al., 2021), and almost all of these studies assume that the learner has access to the entire training data.
Unfortunately, this is not the case in many critical applications.
To see this, consider a scenario where multiple data owners ( e.g. courts or ﬁnancial institutions) have their own private data.
Even if they are willing to coordinate with the other institutions to obtain a single model that works well on the combined data, they cannot directly share their data with the others due to the privacy act.
This precisely sets the core question we aim to answer in this paper – how can we privately train a fair classiﬁer on decentralized data?
To answer this, we ﬁrst study three existing approaches: Unfederated Fair Learning (UFL), Federated Fair Learning via F ED A VG (FFL via F ED A VG ), and Centralized Fair Learning (CFL).
See Fig.
1 for illustration.
Unfederated Fair Learning (UFL) and Centralized Fair Learning (CFL) UFL is the most na¨ıve yet most private approach.
As the name indicates, this strategy refers to a scenario where multiple data owners simply decide to not coordinate.
Instead, each of them learns a fair model on its local data to serve its own users.
This approach is completely private as the participating data owners share nothing with the others.
However, the overall performance of UFL is expected to be poor, because each data owner may have a highly biased view of the entire data distribution, making their locally trained classiﬁers fair only on a biased subset of the data, but not on the entire data.
To evaluate the performance of this approach, we consider the randomized classiﬁer that makes a prediction using a randomly chosen local classiﬁer.
Note that this can be viewed as a random customer model, i.e. , a user drawn from the overall data distribution picks and visits one of the institutions, uniformly at random.
Another extreme approach is CFL, where a fair model is trained on the pooled data.
We expect CFL to achieve the best performance tradeoff, at the cost of no privacy.
Federated Fair Learning via F ED A VG (FFL via F ED A VG ) FFL via F ED A VG applies federated learning (Kone ˇ cn ` y et al., 2017) together with existing fair learning algorithms.
Federated learning is
[Figure]
private
[Figure]
< <
≈
[Figure]
CFL
[Figure]
a distributed learning framework, using which many data owners can collaboratively train a model under the orchestration of a central server while keeping their data decentralized.
For instance, under
F ED A VG , the standard aggregation protocol for federated learning, the central server periodically computes a weighted average of the locally trained model parameters.
If each data owner runs a fair learning algorithm on its own data and these locally trained models are aggregated via F ED A VG , then one might hope to obtain a model that is accurate and fair on the overall data distribution.
We call this approach Federated Fair Learning via F ED A VG (FFL via F ED A VG ).
Goal and Main Contributions
The performances of these approaches have not been rigorously analyzed in the literature.
In the ﬁrst place, it has been unknown whether there is any strict performance gap between UFL and FFL via F ED A VG .
This makes it unclear whether or not federated learning is necessary at all for decentralized fair learning.
The performance comparison between FFL via F ED A VG and CFL also remains unclear.
Can FFL via F ED A VG always match the performance of CFL?
If not, can we develop a better federated learning approach for decentralized fair learning?
Inspired by these open questions, this work rigorously analyzes the performance of the existing approaches and proposes a new solution to decentralized fair learning.
Our major contributions can be summarized as follows:
• We develop a theoretical framework for analyzing various approaches for decentralized fair learning.
Using this, we prove the strict ordering between the existing approaches, i.e. , under some mild conditions, UFL < FFL via F ED A VG < CFL, w.r.t.
their fairness-accuracy tradeoffs.
• Improving upon the state-of-the-art algorithm for (centralized) fair learning (Roh et al., 2021), we design F ED FB, a novel approach to learning fair classiﬁers via federated learning.
• Via extensive experiments, we show that (1) our theoretical ﬁndings hold under more general settings, and (2) F ED FB signiﬁcantly outperforms the existing approaches on various datasets and achieves similar performance as CFL.
To the best of our knowledge, our work is the ﬁrst theoretical performance comparison of various approaches to fair learning on decentralized data.
Moreover, it characterizes the necessity of federated learning for improved fairness-accuracy tradeoff, and we expect this to expedite the adoption of federated learning-based approaches.
Our proposed solution F ED FB achieves state-of-the-art performance on many datasets, sometimes achieving a similar tradeoff as the one trained on centralized data.
R ELATED WORK
Model Fairness Among various algorithms for fair training (Zemel et al., 2013; Jiang & Nachum, 2020;
Zafar et al., 2017c;a;
Hardt et al., 2016; Roh et al., 2021; 2020), the current state-of-the-art is
FairBatch (Roh et al., 2021), which reweights the samples by solving a bi-level optimization problem, whose inner optimizer is the standard training algorithm and outer optimizer aims to ﬁnd the best weights attached to groups of samples for the sake of model fairness.
Federated Learning
Unlike traditional, centralized machine learning approaches, federated learning keeps the data decentralized throughout training, reducing the privacy risks involved in traditional approaches (Kone ˇ cn ` y et al., 2017; McMahan et al., 2017).
F ED A VG (McMahan et al., 2017) is the ﬁrst and most widely used federated learning algorithm.
The idea is to iteratively compute a weighted average of the local model parameters, with the weights proportional to the local datasets’ sizes.
Prior work (Li et al., 2020b) has shown that F ED A VG provably converges under some mild conditions.
The design of our proposed algorithm F ED FB is also based on that of F ED A VG .
Federated Fair Learning for Client Parity There have been only a few attempts in achieving fairness under the federated setting.
Moreover, the deﬁnition of “fairness” used in the existing federated learning work is slightly different from the standard notion used in the centralized setting.
One popular deﬁnition of fairness in the federated setting is that all clients ( i.e. data owners) achieve similar accuracies (or loss values), which we call client parity , and several algorithms have been proposed to achieve this goal (Li et al., 2021; 2020a; Mohri et al., 2019;
Yue et al., 2021; Zhang et al., 2020a).
To compare our methods with existing federated fair learning algorithms designed for client parity, we also extend our F ED FB such that it can also achieve client parity instead of the standard notion of group fairness.
In Sec. 5, we will show that F ED FB can achieve as good client parity as the existing algorithms, though F ED FB is not speciﬁcally designed for client parity. [Figure] Federated Fair Learning for Group Fairness
A few very recent studies (Ezzeldin et al., 2021; Rodr´ıguez-G´alvez et al., 2021; Chu et al., 2021; Du et al., 2021; Cui et al., 2021), conducted concurrently with our work, also aim at achieving group fairness under federated learning. In particular, Du et al. (2021), Rodr ´ ıguez-G ´ alvez et al.
and Chu et al.
(2021) mimic the centralized fair learning setting by exchanging information for each local update.
In contrast, our F ED FB requires much fewer communication rounds, ensuring higher privacy and lower communication costs.
Simlar to F ED FB,
Ezzeldin et al.
(2021) employs F ED A VG and a reweighting mechanism to achieve group fairness.
However, F AIR F ED only applies to the case with one single binary sensitive attribute, while Rodr ´ ıguez-G ´ alvez et al.
and Chu et al.
(2021) are not applicable to demographic parity.
Therefore, we summarize the comparison of UFL, FFL via F ED A VG , CFL, F ED FB and A GNOSTIC F AIR (Du et al., 2021) in terms of performance and privacy in Fig.
There is also work that aims at achieving local fairness for each data owner (Cui et al., 2021).
This is in contrast to our work, which instead focuses on achieving global fairness in the overall data distribution.
Our setting is more appropriate in domains such as criminal justice and social welfare.
P ERFORMANCE A NALYSIS OF UFL, FFL VIA F ED A VG AND CFL
In Sec. 3.1, we ﬁrst show the necessity of federation by proving that FFL via F ED A VG can achieve strictly higher fairness than UFL.
We then prove the limitation of FFL via F ED A VG by comparing its performance with an oracle bound of CFL in Sec. 3.2.
These two results together imply that federated learning is necessary, but there exists a limit on what can be achieved by F ED A VG -based approaches.
We will present informal theoretical statements, deferring the formal versions and proofs to Sec. A.
Problem Setting Denote [ N ] := { 0 , 1 , . . , N − 1 } for any N ∈ Z + . We assume I clients, which have the same amount of data.
We further assume a simple binary classiﬁcation setting with a binary sensitive attribute, i.e. , x ∈ X
= R is the input feature, y ∈ Y
= [1] is the outcome and a ∈ A = [1] is the binary sensitive attribute.
Assume x is a continuous variable.
The algorithm we will develop later in Sec.
4 will be applicable to general settings.
We now introduce parameters for describing the data distribution.
Let y | x ∼ Bern( η (x)) for all client i , where η ( · ) :
X → [0 , 1] is a strictly monotone increasing function.
Assume x | a = a, i = i ∼ P ( i ) a , a | i
=
i ∼ Bern( q i ) , where i is the index of the client, P ( i ) a is a distribution, and q i ∈ [0 , 1] for a = 0 , 1 , i ∈ [ I ] .
Let F = { f : X ×
A → [0 , 1] } .
Given f ∈ F and data sample (x , a) , we consider the following randomized classiﬁer: ˆy
[Equation]
Using these deﬁnitions, we now deﬁne demographic parity, specialized for a binary sensitive attribute:
Deﬁnition 1 (Demographic Parity (binary cases)) .
P (ˆy = 1 | a = 0) =
P (ˆy = 1 | a = 1) .
To measure how unfair a classiﬁer is with respect to demographic parity (DP), we measure DP disparity , i.e. the absolute difference between the two positive prediction rates:
[Equation]
ε0 [-.0 .
-]. 0 0 . 5 1 .ε 1 0 . {+
+}
0 D P
D i s p ( f U F L ε 0 , ε 1 ) 0 .0 .0 .(a)
δ
≈ 0 .ε0 [-.0 .
-].
5 1 .ε 1 0 . {+
+}
0 D P
D i s p ( f U F L ε 0 , ε 1 ) 0 .0 .0 .(b)
δ
≈ 0 .ε0 [-.0 .
-].
5 1 .ε 1 0 . {+
+}
0 D P
D i s p ( f U F L ε 0 , ε 1 ) 0 .0 .0 .(c)
δ ≈ 0 .
3. N ECESSITY OF F EDERATION : FFL VIA F ED A VG IS STRICTLY BETTER THAN UFL
UFL Optimization We now present the optimization problem solved in the UFL scenario.
Here, for analytical tractability, we will assume the population limit, i.e. , the true data distribution is used in optimization.
Recall that clients do not coordinate in this scenario, and each of them solves their own optimization problem to train a locally fair classiﬁer.
In particular, each client i ∈ [ I ] ﬁrst sets its own local fairness constraint ε i ∈ [0 , 1] , and solves the following constrained optimization problem:
[Equation]
We denote by f
ε i i the solution to UFL( i, ε i ).
Recall that the overall performance of UFL is deﬁned as the performance of the following mixture of I classiﬁers:
[Equation]
where f UFL ε := (cid:80) i
[Equation] [ I ] f [Equation] i i (x , a) /I , with ε =
[Equation] [Equation] − 1 ) . The question here is whether the resulting classiﬁer f UFL ε obtained by UFL can achieve an arbitrary level of fairness.
The following lemma shows that UFL cannot achieve a high enough fairness level beyond a certain threshold.
Lemma 1 ((Informal) Achievable fairness range of UFL) .
Let q i = q ∈
(0 , 1) for all i ∈ [ I ] . Under certain conditions, there exists a certain DP disparity threshold δ > 0 such that min ε ∈ [0 , 1] I DP Disp ( f UFL ε ) > δ.
A critical condition of Lemma 1 is that the distribution of insensitive attribute x | a is highly heterogeneous on different clients.
(See the detailed statements in Sec.
A.2.2 and Sec. A.4.)
Therefore, Lemma 1 implies that UFL fails to achieve strict fairness requirements even without data heterogeneity on the distribution of sensitive attribute a .
The following corollary provides an example satisfying the conditions of Lemma 1.
Corollary 2 (Informal) .
Let I = 2 and q {+
+} =
q 1 = 0 .
5 , η ( x ) = 1 1+ e − x , P ( i ) a = N ( µ ( i ) a , σ ( i )2 ) , where i = 0 , 1 .
Under certain assumptions, if one client has much larger variance than the other, there exists δ > 0 such that min ε 0 ,ε 1 ∈ [0 , 1] DP Disp ( f UFL ε ) > δ.
Note that the condition that one client has a much larger variance than the other contributes to the “high data heterogeneity” requirement.
We provide the explicit form of δ in Corollary 9 in Sec.
A.2.2.
Corollary 2 implies that under a limiting case of Gaussian distribution, UFL cannot achieve high fairness requirements.
In Sec. 5.1, we will numerically demonstrate the same claim holds for more general cases.
Next, we give a speciﬁc example that satisﬁes the conditions of Corollary 2, which is visualized in Fig. 3(a).
Example 1.
Let µ (0)0 = µ (0)1 = 0 , µ (1)0 = 3 , µ (1)1 = − 1 , σ (0) =
70 and σ (1) = 1 .
Then, δ ≈ 0 . 21 .
FFL via F ED A VG Optimization FFL via F ED A VG enables federated training of a fair classiﬁer on decentralized data.
In Sec.
A.3.2, we show that the classiﬁer obtained by FFL via F ED A VG is equivalent to f FFL via FedAvg ε , the solution to the following constrained optimization problem.
[Equation]
The following theorem asserts that FFL via F ED A VG can achieve a strictly higher fairness than UFL.
Theorem 3 ((Informal) Fundamental values of federated learning for fairness) .
Let q i = q ∈
(0 , 1) for all i ∈ [ I ] [Equation] Under certain conditions
[Equation] Similar to Lemma [Equation] the technical assumptions include high enough heterogeneity of x | a across the clients.
Thm.
3 shows that even with just two clients ( I = 2 ) [Equation] a non-trivial gap exists between non-federated algorithms and federated algorithms in their fairness performances.
More details are provided in Sec.
A.4.
The theorem asserts that, under certain distributional assumptions, by using the optimal local fairness budgets ε i , FFL via F ED A VG can achieve perfect fairness, while UFL cannot.
Remark 1.
Extending Thm.
3 to general cases where q i are not all the same remains open.
In particular, the analysis of FFL via F ED A VG for those cases remains open.
However, we conjecture that our lemma holds for more general cases [Equation] and we numerically support our conjecture in Sec. 5.
Remark 2.
There is a stark difference between this phenomenon and the well-known gain of federated learning due to an increased sample size, which is almost negligible with a few number of clients.
Our ﬁnding on this untapped gain in fairness can better support the need for federated learning even between a small number of clients, which is the case for most cross-silo federated learning scenarios.
3. FFL VIA F ED A VG IS STRICTLY WORSE THAN CFL
While we showed that FFL via F ED A VG can achieve perfect fairness on certain distributions, it is still unclear whether or not this is the case for every distribution.
In this section, we ﬁrst present the optimization problem for CFL, whose achievable fairness region can serve as an upper bound on that of all other federated learning algorithms.
We then show the existence of data distributions on which FFL via F ED A VG achieves a strictly worse fairness performance than CFL.
This implies a strict gap between the performance tradeoff of FFL via F ED A VG and that of CFL.
CFL Optimization We consider the same problem setting as Sec.
We now model the CFL scenario as the following constrained optimization problem:
[Equation]
Denote the solution to CFL( ε ) as f CFL ε .
It is clear that f CFL ε achieves the best accuracy-fairness tradeoff, at the cost of no privacy.
The following lemma shows that there exists some distribution such that FFL via F ED A VG is strictly worse than CFL when the distribution of sensitive attribute a is heterogeneous ( q i are not all the same).
Lemma 4 ((Informal) A strict gap between FFL via F ED A VG and CFL) .
When there exist i (cid:54) =
j ∈ [ I ] s .
t . q i (cid:54) =
q j , there exist a distribution such that min ε ∈ [0 , 1] I DP Disp ( f FFL via FedAvg ε ) > min ε DP Disp ( f CFL ε ) = 0 .
Remark 3.
A strict gap exists for certain distributions, but not for all distributions.
3. N UMERICAL C OMPARISONS OF A CCURACY - FAIRNESS TRADEOFFS
One limitation of our current theoretical results is that they only compare the maximum achievable fairness.
Note that such analysis reveals how the tradeoff of accuracy and fairness behaves as the fairness level increases, but it fails at fully characterizing the entire tradeoff curve.
Extending our theoretical results to fully characterize such tradeoffs is highly non-trivial, so we leave it as future work.
Instead, we numerically solve each of the optimization problems and visualize the tradeoff curves achieved by different algorithms.
Shown in Fig.
4 are the tradeoff curves for two clients cases.
Let x | a = 0 , i = {+
+} ∼ N (3 , 1) , x | a = 1 , i [-= 
 ∼-]=∼ N (5 , 1) , x | a = 0 , i = 1 ∼ N (1 , 1) , x | a = 1 , i = 1 ∼ N ( − 1 , 1) , a | i = 0 ∼ Bern( q 0 ) , a | i = 1 ∼ Bern( q 1 ) , η ( x ) = 1 1+ e − x , and vary the values of q 0 and q 1 .
Note that | q 1 − q
| captures the heterogeneity of the sensitive data a , which increases from left to right.
First, one can observe that UFL < FFL via F ED A VG < CFL in terms of the achievable fairness range, as predicted by our theory.
Furthermore, we also observe an increasing gap between the tradeoff curves as the data heterogeneity increases.
Theoretical understanding of this phenomenon remains open.
F ED FB FOR I MPROVED F EDERATED F AIR L EARNING
Our ﬁndings in the previous section imply that federated learning is necessary, but the current F ED A VG -based approach might not be the best approach.
Can we design a federated learning algorithm that is strictly better than F ED A VG -based approaches?
In this section, we propose a new federated learning algorithm for fair learning, which we dub F ED FB (short for Federated FairBatch).
Our approach is based on the state-of-the-art (centralized) fair learning algorithm FB (short for FairBatch)
(Roh et al., 2021) and has a few desirable theoretical guarantees.
Later in Sec. 5, we empirically show that F ED FB outperforms FFL via F ED A VG and closely matches the CFL’s tradeoff on various datasets. Algorithm 1: F ED FB algorithm
ClientUpdate ( i, w , λ ) :
Update w ( i ) according to the sample weights λ ; L y,a ← a ServerExecutes: for each iteration do Clients perform updates; w ← SecAgg ( { w ( i ) } ) ;
L y,a ← SecAgg ( { L ( i ) y,a } ) , ∀ ( y, a ) ; λ ← Update ( λ , L y,a ) ; Broadcast w and λ to clients; output :
w We ﬁrst provide a brief review of the FB algorithm.
FB solves a bi-level optimization problem to learn a fair classiﬁer on centralized data.
The inner optimization problem solves a weighted empirical risk minimization problem where samples from different groups are reweighted by different weights.
The outer optimization problem optimizes the weights used for the inner problem, with the goal of minimizing the unfairness of the classiﬁer.
FB works for various group fairness deﬁnitions including demographic parity, equalized odds, and equalized opportunity.
For the case of demographic parity, the algorithm reduces to the following simple yet intuitive algorithm.
The algorithm starts with equal weights for two different groups.
After training a model with the initial weights, it computes the sign of the difference between the two positive prediction rates P (ˆy = 1 | a = 0) − P (ˆy = 1 | a = 1) .
If this quantity is zero, then DP Disp is zero, so the sample weights are not updated.
If this is positive, it decreases the weights for the samples whose y = 1 , a = 0 and increases the weights for the samples whose y = 1 , a = 1 so that after retraining, P (ˆy = 1 | a = 0) decreases and P (ˆy = 1 | a = 1) increases.
And vice versa for the other case.
F ED FB is a simple modiﬁcation of the original FB, which closely simulates the centralized FB applied to the entire data.
Recall that under the F ED A VG protocol, clients periodically share their locally trained model parameters with the server.
Our modiﬁcation is based on the following simple observation: the bi-level structure of FB naturally ﬁts the hierarchical structure of federated learning.
More speciﬁcally, note that if the clients also share their group-speciﬁc positive prediction rates, then the centralized server can immediately reconstruct the difference between the two positive prediction rates, measured on the entire data distribution.
Therefore, the update rules for the outer optimization of the original FB algorithm can be implemented at the central server given the extra information.
Then, the central server can broadcast the updated group weights with the clients, which can then locally train models with the newly reweighted samples.
This precisely describes the essence of F ED FB, and shown in Alg.
1 is the pseudocode of the
F ED FB framework.
Note that the update rule for group weights (denoted by λ in the pseudocode) only requires the sum of the group losses, which enables secure aggregation.
In Sec.
B.1, we present the detailed description of the algorithm, which consists of the local training algorithm with [Table] reweighted samples, the model/loss aggregation protocol, the group-weight update algorithm, and the model/group-weight distribution protocol.
We highlight a few advantages of F ED FB.
First, it provably converges under some mild technical conditions.
We proved it by leveraging the analysis tools for federated learning and FB – See Thm. 23 for more details.
Second, our algorithm is a strict improvement of FB even in centralized data cases.
The original FB algorithm was not applicable if the sensitive attributes are not binary.
We made appropriate changes to the algorithm (with theoretical guarantees) so that it can also handle more general cases.
Thus, we use our version of FB by default for fair learning in the rest of this paper.
One can note that under F ED FB, clients exchange additional information with the server by communicating real-valued loss values in addition to the model parameters.
To limit the information leakage, we also consider a variant of F ED FB, which exchanges the quantized loss values.
For instance, “F ED FB(10bits)” means each loss value is uniformly quantized using 10 bits.
Such a loss quantization scheme limits the amount of additional information shared between the clients and the server, at the cost of potentially inaccurate group weight updates.
E XPERIMENTS
In this section, we numerically study the performance of UFL, FFL via F ED A VG , and CFL for more general cases, and evaluate the empirical performance of F ED FB.
We investigate the fundamental limitation of UFL under general Gaussian distribution.
We compare the accuracy-fairness tradeoff of UFL, FFL via F ED A VG , and CFL by numerically solving UFL( i, ε i ), FFL via F ED A VG ( ε ) , and CFL( ε ).
More speciﬁcally, we ﬁrst characterize the solutions to these problems up to an unknown scalar, which can be numerically optimized.
See Sec.
A for more details.
Moreover, we evaluate
F ED FB on both demographic parity and client parity.
In each simulation study, we report the summary statistics across ﬁve replications.
Similar to the experimental settings used in (Roh et al., 2020), we train all algorithms using a two-layer ReLU neural network with four hidden neurons to evaluate the performance of F ED FB for the non-convex case.
The results for logistic regression are provided in Sec.
C. We also investigate the empirical relationship between the performance of F ED FB and the number of clients and incorporate differential privacy to further strengthen the power of F ED FB.
More implementation details are included in Sec.
C.
5. L IMITATION OF UFL ON GENERAL CASES
The ﬁrst experiment examines the fairness range of UFL under a more general Gaussian distribution, which does not satisfy the conditions of Corollary 2.
For instance, if the variance of two clients is similar, then the conditions do not hold.
However, we still conjecture that the same phenomenon holds for more general distributions, and we corroborate our conjecture with numerical experiments.
Shown in Fig.
3(b,c) are the numerically computed lower bound on UFL’s achievable fairness.
In particular, for (b), we let x | a = 0 , i = 0 ∼ N (10 , 0 .
2 2 ) , x | a = 1 , i =
∼ N (9 . 8 , 0 .
2 2 ) , x | a = 0 , i = 1 ∼ N (0 . 2 , 0 . 2 2 ) , x | a = 1 , i = 1 ∼ N (0 , 0 .
2 2 ) , a ∼ Bern(0 . 2) , and for (c), we let x | a = 0 , i = 0 ∼ N (3 , 1) , x | a = 1 , i =
∼ N (5 , 1) , x | a = 0 , i = 1 ∼ N (1 , 1) , x | a = 1 , i =∼ N ( − 1 , 1) , a ∼ Bern(0 . 5) .
For both cases, we set η ( x ) = 1 1+ e − x .
It is easy to check that these distributions do not satisfy the conditions of Corollary 2.
In particular, the distribution (b) corresponds to the case that the same group is favored on both clients, and the positive rates of each group in different clients are distinctive.
The distribution (c) represents the case that different groups are favored on two clients.
In both cases, we can see that UFL fails to achieve perfect fairness, i.e. , δ > 0 .
We also observe that δ is large on the distribution (c), where different groups are favored on two clients.
This supports our conjecture that UFL’s fairness performance is strictly limited not only on certain data distributions but also on more general ones.
5. A CCURACY - FAIRNESS TRADEOFFS OF UFL, FFL VIA F ED A VG AND CFL
The second experiment extends the experiments conducted in Sec. 3.3.
We assess the relationship between the data heterogeneity and the gap between the three fair learning scenarios with three clients.
F ED FB achieves good performance on all the tested levels of heterogeneity.
This is because by design, F ED FB closely matches the operation of CFL, whose performance is independent of data heterogeneity.
[Table]
As shown in Fig.
8, FFL via F ED A VG is observed to achieve a strictly worse tradeoff than CFL and a strictly higher maximum fairness value than UFL.
The results corroborate the beneﬁt and limitation of F ED A VG -based federated learning in improving fairness.
A very interesting observation is that UFL is observed to obtain a strictly higher accuracy than FFL via F ED A VG .
Indeed, this could be attributed to the fact that the average of locally fair models might not be fair to any sub-distribution, while UFL at least ensures that each component of the mixture classiﬁer is fair on some sub-distribution.
5. F ED FB EVALUATION ON DEMOGRAPHIC PARITY
We assess the empirical performance of F ED FB for both convex and non-convex cases on four datasets and the performance of F ED FB under different data heterogeneity.
We focus on demographic parity and report DP disparity = max a ∈ [ A ] | P (ˆy = 1 | a = a ) − P (ˆy = 1) | , where A is the number of groups.
Note that this is slightly different from the deﬁnition we used in the previous sections, which was used speciﬁcally for the case of one binary sensitive attribute.
Baselines We employ three types of baselines: (1) decentralized non-fair training (F ED A VG ); (2) decentralized fair training (UFL, FFL via F ED A VG ); (3) centralized fair training (A GNOSTIC F AIR , CFL).
Here, for all the algorithms that involve fair training, we use our improved version of FB, which is the state-of-the-art fair learning algorithm on centralized data.
for fairer comparison and better performance, the implementation of UFL, FFL via F ED A VG , and CFL are all based on FB.
Note that UFL is absolutely private, CFL violates the privacy policy, F ED A VG , FFL via F ED A VG , and F ED FB share some information at communication rounds without directly sharing the data, and
A GNOSTIC F AIR exchanges information for each local update.
To have a fairer comparison between FFL via F ED A VG and F ED FB, we also equalize their differential privacy guarantees (Dwork, 2008) and compare their performances.
See Sec.
C for more details.
We also report the performance of
F AIR F ED , a recently proposed algorithm for achieving demographic parity for binary sensitive groups in the federated setting (Ezzeldin et al., 2021), and A GNOSTIC F AIR in Sec.
C.
Datasets (synthetic)
We follow Roh et al.
(2021) for data generation, but with a slight modiﬁcation to make the dataset more unbalanced.
To study the empirical relationship between accuracy, fairness, and data heterogeneity, we split the dataset in different ways to obtain desired levels of data heterogeneity.
More details are given in Sec.
C.2.
(real)
We use three benchmark datasets: Adult (Dua & Graff, 2017) with 48,842 samples, COMPAS (ProPublica, 2021) with 7,214 samples, and Bank (Moro et al., 2014) with 45,211 samples.
We follow Du et al.
(2021)’s method to preprocess and split Adult into two clients and Jiang & Nachum (2020)’s method to preprocess COMPAS and Bank.
Then, we split COMPAS into two clients based on age and split Bank into three clients based on the loan decision.
Note that all the datasets are split in heterogeneous ways.
[Figure] [Figure] Results We present the results for two-layer ReLU neural networks in Table 1 and leave the results for logistic regression in Sec.
C. Tablereports the test accuracy and DP disparity of four baselines and F ED FB.
We see a substantial fairness improvement obtained by F ED FB.
As expected, the resulting fairness level of F ED FB is close to that of CFL and
A GNOSTIC F AIR .
Besides, we observe the poor performance of UFL and FFL via F ED A VG , which is due to the fundamental limitation of UFL and FFL via F ED A VG .
Table 2 reports the accuracy and fairness of each method under different data heterogeneity.
FedFB is observed to be robust to data heterogeneity.
This agrees with our expectation as F ED FB mimics the operation of CFL – which is not affected by data heterogeneity – as much as possible by design.
We make a more thorough comparison between CFL and F ED FB by plotting the accuracy-fairness tradeoff curves in Fig.
To demonstrate the performance gain does not come at the cost of privacy loss, we restrict F ED FB to only exchange 10 bits of information per communication round.
Fig.
5 showcases the beneﬁt of F ED FB in terms of accuracy, fairness and privacy.
In Table 7 and Table 8 in Sec.
C, we compare F ED FB and F AIR F ED . One can observe that F ED FB can achieve a strictly improved fairness than F AIR F ED . Also, F ED FB is observed to be more
[Figure]
robust to data heterogeneity.
Table 9 in Sec.
C shows that F ED FB achieves similar performance as
A GNOSTIC F AIR , at much lower cost of privacy.
We evaluate the performance of F ED FB in achieving client parity (CP) and compare it with the state-of-the-art algorithms for CP.
We will measure CP disparity =
max i (cid:54) =
j ∈ [ I ] | L ( i ) − L ( j ) | .
Here L ( i ) is the loss in i th client, see Sec. B.4 for more detail. Baselines We consider GIFAIR (Yue et al., 2021), Q -FFL (Li et al., 2020a), D ITTO (Li et al., 2021), and the unconstrained baseline F ED A VG (McMahan et al., 2017).
GIFAIR and Q -FFL are the most similar ones to F ED FB.
Similar to F ED FB, both GIFAIR and Q -FFL propose a modiﬁed aggregation protocol, under which clients share some additional information with the central server, which then accordingly adjust the objective function used for the next round of training.
The key difference is that while F ED FB optimizes the coefﬁcients for the primary objective terms ( i.e. sample reweighting) by solving a bi-level optimization problem, GIFAIR updates the coefﬁcient for the penalty terms, and Q -FFL implicitly updates the weights on each objective term based on nonlinear behaviors of polynomial functions, which is equivalent to the α -fairness algorithm used in networking (Mo &
Walrand, 2000).
The D ITTO algorithm combines multitask learning with federated learning to learn a personalized classiﬁer for each client, improving the accuracy of the clients with low accuracy.
Datasets We use the same datasets as Sec. 5.3, but split the datasets according to their sensitive attributes to simulate the same setting as assumed by GIFAIR, Q -FFL, and D ITTO .
Results Fig.
6 shows that F ED FB offers competitive and stable performances in mitigating the model bias, especially in the high fairness region.
Although Q -FFL achieves better accuracy and fairness on the synthetic data, under strict fairness constraint, F ED FB and its private variant nearly achieves the highest accuracy on the other three datasets.
C ONCLUSIONS
Summary We have investigated how one can achieve group fairness under a decentralized setting.
For the ﬁrst time in the literature, we developed a theoretical framework for decentralized fair learning algorithms and analyzed the performance of UFL, FFL via F ED A VG , and CFL.
As a result, we provide novel insights that (1) federated learning can signiﬁcantly boost model fairness even with only a handful number of participating clients, and (2) F ED A VG -based federated fair learning algorithms are strictly worse than the oracle upper bound of CFL.
To close the gap between F ED A VG -based fair learning algorithms and CFL, we propose F ED FB, a new federated fair learning algorithm.
The key idea behind F ED FB is that each client shares extra information about the unfairness of its local classiﬁer with the server, which then computes the optimal samples weights that need to be used for the following round of local training.
Our extensive experimental results demonstrate that our proposed solution F ED FB achieves state-of-the-art performance, while still ensuring data privacy.
Open questions (Theory) While we characterized some fundamental limits on tradeoffs of various approaches, there still remains a large number of open questions.
First, as we brieﬂy mentioned in Sec. 3.3, full theoretical characterization of accuracy-fairness tradeoff still remains open.
Our current theoretical results only study the extreme ends of the tradeoff curves.
Moreover, as shown in Sec. 5.2, some of our experimental results reveal a highly nontrivial phenomenon.
Studying this phenomenon and identifying the exact relationship between various learning algorithms is an interesting open problem.
Furthermore, a three-way tradeoff between accuracy, fairness, and privacy remains widely open.
(Algorithm)
It remains open whether or not our proposed solution F ED FB can be applied for achieving different fairness notions used in the federated setting.
In particular, proportional fairness , i.e. , clients who contribute more should receive more rewards (Zhang et al., 2020b; Lyu et al., 2020b;a), is another popular notion of fairness used in the federated setting, and our current F ED FB cannot handle it.
Extending F ED FB to handle proportional fairness is one future research direction.
E THICS STATEMENT
This work will improve the well-being of individuals in our society by solving ethical issues of AI, such as the implicit discrimination in machine learning algorithms and the privacy of sensitive data.
Our theoretical and empirical ﬁndings assert that a fair machine learning model can be reliably trained on decentralized data without compromising much privacy.
R EPRODUCIBILITY STATEMENT
We have released our implementation in anonymous github 1 , which contains the code for all the experiments, including the datasets we use and the implementation of data processing steps.
For the theoretical results, we provide all the necessary assumptions and proof in the Appendix.
A A PPENDIX - UFL, FFL VIA F ED A VG , CFL ANALYSIS
In this section, we provide the concrete analysis for UFL, FFL via F ED A VG , and CFL.
For illustration purposes, we will start by discussing two clients cases, and then extend the analysis into more clients cases in Sec.
A.4.
We begin with the analysis of CFL in Sec.
A.1.
Then we analyze UFL and FFL via F ED A VG . To be speciﬁc, in Sec.
A.2, we analyze the limitation of UFL and present the formal version of Lemma 1 under two clients cases and Corollary 2.
In Sec.
A.3, we analyze FFL via F ED A VG and compare it with UFL and CFL, then we present the formal two-client version of Thm. 3 and
Lemma 4.
All the multi-client statements are included in Sec.
A.4 We summarize the commonly used notations in Table 3 .
A. CFL ANALYSIS
In this section, we analyze the CFL classiﬁer f CFL ε given in CFL( ε ).
We mainly derive the solution of CFL( ε ) in Lemma 5.
In Lemma 6 and Lemma 7 we summarize the properties of f CFL ε .
Lemma 5.
Let q ∈ Deﬁne g ( · ) : [ − max( q, 1 − q ) , max( q, 1 − q )]
→ [ − 1 , 1] as g ( λ ) =
(cid:90)
[Equation]
[Table] [Equation] [Table]
[Equation]
1 − q ) ) , + ∞ ]
d P 0 − (cid:90) [ η − 1 ( 12 + λ 2 q ) , + ∞ ] d P 1 , then f CFL ε = { (cid:74) s ( x, a ) > 0 (cid:75) + α (cid:74) s ( x, a ) = 0 (cid:75) : α ∈ [0 , 1] } , where s ( x, 0) =
2 η ( x ) − 1 + λ 1 − q , s ( x, 1) = 2 η ( x ) − 1 − λq , λ = g − 1 (sign( g (0))
min { ε, | g (0) |} ) .
Here we denote the indicator function as (cid:74) E (cid:75) :
(cid:74) E (cid:75)
= 1 if E is true, zero otherwise.
Proof.
The proof is similar as Menon & Williamson (2018).
To solve CFL( ε ), we ﬁrst write the error rate and the fairness constraint as a linear function of f .
Let p a ( · ) be the pdf of P a , where a = 0 , 1 .
Denote the joint distribution of x and a as p x , a ( x, a ) .
Note that
[Equation]
and
[Equation]
[Equation]
Denote the function that minimizes the error rate (ERM) as ˜ f ∈ F .
It is easy to see that,
[Equation]
Next, consider the following three cases.
In particular, we provide the proof for | MD ( ˜ f ) | ≤ ε and
MD ( ˜ f ) > ε .
The proof for MD ( ˜ f ) < − ε is similar as the proof for MD ( ˜ f ) > ε .
Case 1.
| MD ( ˜ f ) | ≤ ε : ERM is already fair.
The solution to (1) and CFL( ε ) is ˜ f .
Case 2.
MD ( ˜ f ) >
ε : ERM is favoring group 0 over group 1.
We will show that solving (1) is equivalent to solving an unconstrained optimization problem.
First, we will prove by contradiction that the solution f (cid:63) ∈ F to (1) satisﬁes MD ( f (cid:63) ) =
ε .
We use f (cid:63) ∈ F to denote the solution of (1).
Suppose the above claim does not hold.
Then we have
MD ( f (cid:63) )
< ε .
To show the contradiction, we construct a f (cid:48) ∈ F that satisﬁes the fairness constraint and has a lower error rate than that of f (cid:63) .
Let f (cid:48) be a linear combination of f (cid:63) and ˜ f :
[Equation]
where a =
[Equation]
Then we obtain
[Equation]
ε. Denote the error rate P { ˆy (cid:54) =
y } as e : F → [0 , 1] .
Then the error rate of f (cid:48) is
[Equation]
which is inconsistent to the optimality assumption of f (cid:63) .
Therefore, MD ( f (cid:63) ) = ε .
Now, solving CFL( ε ) is equivalent to solving
[Equation]
Furthermore, the optimization problem above is also equivalent to
[Equation]
for all λ ∈ R .
Next, our goal is to select a suitable λ such that the constrained optimization problem above becomes an unconstrained problem, i.e. , we will select a suitable λ such that the minimizer to the unconstrained optimization problem (2) satisﬁes equality constraint (3).
Note that
[Equation]
then the solution to unconstrained optimization problem (2) is
[Equation]
[Figure]
where
[Equation]
Since the range of η ( x ) is [0,1], ¯ f with λ > max( q, 1 − q ) is no different from ¯ f with λ = max( q, 1 − q ) ; ¯ f with λ < − max( q, 1 − q ) is no different from ¯ f with λ = − max( q, 1 − q ) .
Therefore, the only thing left is to ﬁnd the λ ∈ [ − max( q, 1 − q ) , max( q, 1 − q )] such that ¯ f satisﬁes the constraint (3).
Now consider the mean difference between the positive rate of two groups:
[Equation]
P= g ( λ ) .
Note that g ( · ) :
[ − max( q, 1 − q ) , max( q, 1 − q )] → [ − 1 , 1] is a strictly monotone increasing function.
Consequently, if and only if λ = g − 1 ( ε ) , ¯ f satisﬁes (3).
Recall that optimization problem (2) with constraint (3) is equivalent as CFL( ε ).
Thus, let λ = g − 1 ( ε ) and ¯ f is the solution of CFL( ε ).
Case 3.
MD ( ˜ f ) < − ε : ERM is favoring group 1 over group 0.
Similarly, like Case 2, we obtain that the solution CFL( ε ) is
[Equation]
where
[Equation]
and λ = g − 1 ( − ε ) .
Combining all the cases above yields the desired conclusion.
The proof is now complete.
Remark 4.
Select α = 0 , then the solution to CFL( ε ) can be written as
[Equation]
Therefore, Lemma 5 implies that the best classiﬁer of the CFL problem is equivalent to simply applying a constant threshold to the class-probabilities for each value of the sensitive feature.
Lemma 5 suggests the following property of the solution to CFL( ε ).
Lemma 6.
If f and g are two solutions to CFL( ε ), then f = g almost everywhere.
For illustration purposes, we denote
[Equation]
Below we summarize some useful properties of λ CFL ε .
Lemma 7.
The sign of λ CFL ε and MD ( f CFL ε ) are determined by g (0) .
If ε < | g (0) | , then MD ( f CFL ε ) =
λ CFL ε (cid:54) = 0 , and g ( λ CFL ε ) =
sign( g (0))
ε .
If | g (0) | ≤ ε, then λ CFL ε = 0 and MD ( f CFL ε ) =
g ( λ CFL ε ) = g (0) .
If g (0) > 0 or g (0) < 0 , then for any ε ≥ 0 , we have λ ≤ 0 or λ ≥ 0 , respectively.
Proof.
The ﬁrst property follows directly from the deﬁnition of λ CFL ε .
Next, we prove the second property.
When ε > | g (0) | , we have λ =
and the ﬁrst property holds.
When g (0) > ε > 0 , by the deﬁnition of λ CFL ε , we have λ = g − 1 ( ε ) <
g − 1 ( g (0))
= 0 .
When g (0) < − ε < 0 , we have λ = g − 1 ( − ε ) >
g − 1 ( g (0))
= 0 .
Combining all the cases above yields the desired conclusion.
A. UFL ANALYSIS
With the analysis of CFL in Sec.
A.1, in this section, we analyze the UFL classiﬁer UFL( i, ε i ) for the case of two clients. For illustration purpose, with I = 2 , we denote f UFL ε 0 , [Equation]
In Sec.
A.2.1 we introduce some notations for the UFL classiﬁer f UFL ε 0 ,ε 1 that follows from Lemma 5.
In Sec.
A.2.2 we analyze the limitation of f UFL ε 0 ,ε 1 as stated in Sec. 3.1.
To be more speciﬁc, we present the two clients’ version of Lemma 1, formal version of Corollary 2 and conclude their proof.
In Sec.
A.2.3, we analyze the performance gap between f UFL ε 0 ,ε 1 and CFL classiﬁer f CFL ε .
A.2. P ROBLEM SETTING
By Lemma 5, the solution to UFL( i, ε i ) is
[Equation]
where the associated λ UFL i ε i is deﬁned as
[Equation]
6) and g
[Equation]
[Equation]
=
[Equation]
Note that g i ( λ ) is the mean difference on i th client E x ∼P ( i )
f (x , 0) − E x
∼P ( i )
f
(x , 1) of the classiﬁer of the form (4).
Now, the demographic disparity for f UFL ε 0 ,ε 1 can be written as
[Equation]
For ease of notation, we deﬁne local mean difference on i th client as MD i ( f )
= P (ˆy = 1 | a = 0 , i = i ) − P (ˆy = 1 | a = 1 , i = i ) and local demographic disparity on i th client as
DP Disp i ( f ) = | MD i ( f ) | , where i = 0 , 1 .
Since the overall distribution of the data samples is x | a = a ∼ P a = P (0) a / 2 + P (1) a / 2 , a = 0 , 1 , g (see the deﬁnition of g in Lemma 5) and g 0 , g 1 has the following relation:
[Equation]
A.2. L IMITATION OF UFL
In this section, we mainly analyze the limitation of UFL in Lemma 8, which shows that f UFL ε 0 ,ε 1 can not achieve 0 demographic disparity in certain cases.
Corollary 9 is a speciﬁc example of Lemma 8.
Lemma 8 (Formal version of Lemma 1 under two clients cases) .
Let q ∈
Let c =
min
{| g 0 (0) | , | g 1 (0) |} .
Deﬁne ψ : [0 , c ] × [0 , c ] → [ − 1 , 1] as ψ ( [Equation] [Equation] ) =
[Equation]
(sign [Equation] + [Equation]
[Equation] (sign( g [Equation]
[Equation]
ε 0 ))
[Equation]
If g 0 (0) g 1 (0) < 0 and ψ ( ε 0 , ε 1 )( g 0 (0) + g 1 (0)) > 0 for all ε 0 , ε 1 ∈ [0 , c ] , then for all ε 0 , ε 1 ∈ [0 , 1] , DP Disp ( f UFL ε 0 ,ε 1 ) ≥ δ = min {| ψ ( ε 0 , ε 1 ) | : ε 0 , ε 1 ∈ [0 , c ] } > 0 .
Proof.
Deﬁne δ = min {| ψ ( ε 0 , ε 1 ) | : ε 0 , ε 1 ∈ [0 , c ] } .
The goal is to show that the demographic disparity has a positive lower bound.
Note that the mean difference can be expressed as
[Equation]
In the following proof, we will show, the mean difference cannot reach 0.
Without any loss of generality, assume | g 0 (0) | < | g 1 (0) | .
First we consider g 1 (0) > 0 .
We will discuss g 1 (0) < 0 later.
By g 0 (0) g 1 (0) < 0 and ψ ( ε 0 , ε 1 )( g 0 (0) + g 1 (0)) > 0 for all ε 0 , ε 1 ∈ [0 , c ] , we have g 0 (0) < 0 and ψ ( ε 0 , ε 1 ) > 0 for all ε 0 , ε 1 ∈ [0 , c ] .
First, we will prove that UFL achieves its lowest mean difference when ε 0 , ε 1 ∈ [0 , c ] .
In what follows, we consider ﬁve different cases to derive the desired result.
Case 1.
ε 0 > | g 0 (0) | , ε 1 > | g 1 (0) | : ERM is fair on both clients.
By (6), we have λ UFL 0 ε= λ [Equation] 1 ε= 0 .
Recall g i ( · ) is a monotone increasing function, we combine g 1 (0) > 0 and Lemma 7 to have g
( g − 1 1 (0)) <
g 0 (0) < 0 .
Applying the above conclusion yields
[Equation]
Case 2.
ε 0 ≤ | g 0 (0) | , ε 1 > | g 1 (0) | : ERM is unfair on client 0, but fair on client 1.
Applying (6) results in λ UFL 1 ε= 0 .
By the fact that g i ( · ) is a strictly monotone increasing function, we have λ UFL 0 ε= g − 1 0 ( − ε 0 ) >
g − 1 0 ( g 0 (0))
= 0 .
Applying the above conclusion yields
[Equation]
Case 3.
ε 0 ≤ | g 0 (0) | , ε 1 ≤ | g 1 (0) | : ERM is unfair on both client 0 and client 1.
Applying (6) we have λ UFL 0 ε
[Equation]
ε 1 ) .
Then we have
[Equation]
Case 4.
ε 0 > | g 0 (0) | , ε 1 ≤ | g 0 (0) | : ERM is fair on client 0 and very unfair on client 1.
By (6), we have λ UFL 0 ε
[Equation]
[Equation]
) > g
[Equation]
Then we obtain
[Equation]
Case 5.
[Equation]
is fair on client 0 and unfair on client 1. Applying (6) implies λ UFL 1 ε= g −
[Equation]
1 ( ε
[Equation]
) > g − [Equation]
Therefore,
[Equation]
Combining all the cases above, we conclude that when g 1 (0) > 0 DP Disp ( f UFL ε 0 ,ε 1 ) ≥ δ = min {| ψ ( ε 0 , ε 1 ) | : ε 0 , ε 1 ∈ [0 , c ] } > 0 for all ε 0 , ε 1 ∈ [0 , 1] .
Now we consider g 1 (0) < 0 , by the setting | g 0 (0) | < | g 1 (0) | and the assumption g 0 (0) g 1 (0) <and ψ ( ε 0 , ε 1 )( g 0 (0) + g 1 (0))
> 0 , we have g 0 (0) > 0 and ψ ( ε 0 , ε 1 ) < 0 for all ε 0 , ε 1 ∈ [0 , c ] .
Following similar computation above, Case 1 - Case 5 become:
Case 1.
ε 0 > | g 0 (0) | , ε 1 > | g 1 (0) | .
Now we have 0 < g 0 (0) <
g 0 ( g − 1 1 (0)) , thus
[Equation]
Case 2.
ε 0 ≤ | g 0 (0) | , ε 1 > | g 1 (0) | .
Now we have g 0 (0) >
ε 0 , g 1 ( λ UFL 0 ε) <
g 1 (0) , thus [Equation]
Case 3.
In this case we have
[Equation]
Case 4.
Now we have λ UFL 1 ε= g [Equation] [Equation] ε 1 ) <
g [Equation] 1 1 (0) , thus
[Equation]
≤ − [Equation]
Case 5.
Now we have λ UFL 1 ε [Equation]
g [Equation] [Equation] ) <
g [Equation] [Equation] [Equation]
, thus [Equation]
Then we conclude the proof.
Remark 5.
Note that c is the smallest local demographic disparity the ERM achieves on clients.
The condition g 0 (0) g 1 (0) < 0 implies that the ERM is favoring different groups in different clients.
The condition ψ ( ε 0 , ε 1 )( g 0 (0) + g 1 (0)) > 0 for all ε 0 , ε 1 ∈ [0 , c ] implies that f UFL ε 0 ,ε 1 favors the same group as ERM when the constraint is very tight.
If the conditions above hold, Lemma 8 suggests that there exists a lower bound of all the demographic disparity that UFL can achieve.
In particular, if the conditions above hold, UFL fails to achieve perfect demographic parity.
Among the conditions of Lemma 8, g 0 (0) g 1 (0) < 0 can be satisﬁed by the distribution with high data heterogeneity.
To demonstrate the condition ψ ( ε 0 , ε 1 )( g 0 (0) + g 1 (0))
>
for all ε 0 , ε 1 ∈ [0 , c ] can be satisﬁed, we consider a limiting Gaussian case.
The following corollary serves as an example that satisﬁes the conditions of Lemma 8, and provides a more explicit expression of the lowest demographic disparity UFL can reach in the Gaussian case.
Corollary 9 (Formal version of Corollary 2) .
Let q = 0 .
5 , η ( x [Equation] =
[Equation]
where ( µ (0)0 − µ (0)1 )( µ (1)0 − µ (1)1 ) < 0 .
Then DP Disp ( f UFL ε 0 ,ε 1 ) ≥ δ ≈ 14 | g 0 (0) + g 1 (0) | > 0 for all ε 0 , ε 1 ∈ [0 , 1] if one of the following condition holds:
σ (0) (cid:29) σ (1) , | µ (0)0 | , | µ (0)1 | , | µ (1)0 | , | µ (1)1 | and µ (1)0 > µ (1)1 : client 0 has much larger variance than client 1, and client 1 is favoring group 0; 2.
σ (1) (cid:29) σ (0) , | µ (0)0 | , | µ (0)1 | , | µ (1)0 | , | µ (1)1 | and µ (0)0 > µ (0)1 : client 1 has much larger variance than client 0, and client 0 is favoring group 0.
Proof.
In this example, note that local mean difference function of λ can be written as:
[Equation]
where Φ( · ) is the CDF of the standard Gaussian distribution.
We only provide the proof for condition 1, and the proof for condition 2 is similar.
Assume condition 1 holds.
By ( µ (0)0 − µ (0)1 )( µ (1)0 − µ (1)1 ) < 0 and µ (1)0 − µ (1)1 > 0 , we have µ (0)0 − µ (0)1 < 0 .
By (9), we have g 0 (0) <
and g 1 (0) > 0 .
Consequently, combining Lemma 7 and (7) yields
[Equation]
First we show that ψ ( ε 0 , ε 1 ) reachs its minimum either at ( c, 0) or (0 , c ) by taking the derivative of ψ , where c = min {| g 0 (0) | , | g 1 (0) |} is the smallest local demographic disparity.
And then, we will estimate the minimum of ψ on [0 , 1] ×
We take the derivative of ψ with respect to ε i and get
[Equation]
By condition 1, we have g 0 (0) =
Φ( − µ (0)1 σ (0) ) − Φ( − µ (0)0 σ (0) )
≈ 0 , thus | g 0 (0) | (cid:28) | g 1 (0)
| and c = | g 0 (0) | .
Since g i are increasing function, i = 0 , 1 , we have g (cid:48) i ( · ) > 0 , and thus ∂ψ∂ε 0 < 0 , ∂ψ∂ε 1 > 0 .
Therefore, ψ reaches its extreme value at (0 , c ) and ( c, 0) .
Now, we evaluate
[Equation]
where the inequality comes from g 0 (0) < 0 to have g 1 ( g − 1 0 (0))
> g 1 (0) .
And at ( c, 0) , we have
[Equation]
In what follows, we will show that min { ψ ( c, 0) , ψ (0 , c ) } ≈ δ = g 1 (0)+ g 0 (0)by proving that 0 > g 0 ( g − 1 1 ( c )) > g 0 ( g − 1 1 (0))
≈ 0 .
Consider ψ ( c, 0) and ψ (0 , c ) .
Since g 1 (0) > c, g 0 (0) < 0 , we have g 0 ( g − 1 1 (0)) <
g 0 ( g − 1 1 ( c )) <
g 0 (0) < 0 .
Therefore, the only thing left is to show g 0 ( g − 1 1 (0))
≈ 0 .
We divide the rest of the proof into the following three cases.
Case 1.
µ (1)1 < µ (1)0 < 0 : on client 1, the local classiﬁer is favoring group 0 over group 1, and the positive rate of both groups are under 1 2 .
Clearly, under this case, we have (cid:82) [
[Equation]
1 ( 12 ) , ∞
[Equation]
< 12 .
We select λ (cid:48) < 0 such that η − 1 ( 12 + λ (cid:48) )
=
µ (1)1 .
Then we have (cid:82) [ η − 1 ( 12 + λ (cid:48) ) , ∞ )
d P (1)
[Equation]
[ µ [Equation] [Equation] 1 , ∞ )
d P [Equation] [Equation] = 12 , while (cid:82)
[Equation]
< 0 .
Thus we get g 1 ( λ (cid:48) ) < 0 .
Combining g 1 (0) > 0 and intermediate value theorem results in λ (cid:48) <
g − 1 1 (0) < 0 .
Then we obtain
[Equation]
By plugging (10) into (9), we have the other side of g 0 ( g − 1 1 (0)) < 0 is bounded by g 0 ( λ (cid:48) )
=
Φ( µ (1)1 − µ
[Equation]
[Equation]
1 σ (1) )
[Equation]
− µ
[Equation] [Equation] [Equation]
Since σ (1) (cid:29) | µ (1)1 | , | µ (0)1 | , we get g
( g − 1 1 (0))
≈ 0 .
Case 2.
< µ (1)1 < µ (1)0 : on client 1, the local classiﬁer is favoring group 0 over group 1, and the positive rate of both groups are above 12 .
This proof of this case is similar to Case 1.
Case 3.
µ (1)1 < 0 < µ (1)0 : with respect to the local classiﬁer trained by client 1, the positive rate of group 0 is above 12 while that of group 1 is under 12 .
Without any loss of generality, we assume | µ (1)1 | < | µ (1)0 | .
Select λ (cid:48)(cid:48) < 0 such that η ( 12 − λ (cid:48)(cid:48) )
=
µ (1)0 .
Clearly (cid:82) [ η [Equation] [Equation] , +
[Equation]
[Equation] [Equation] = 12 , while
[Equation]
>2 .
Consequently, we get g 1 ( λ (cid:48)(cid:48) )
< 0 and λ (cid:48)(cid:48) <
g − 1 1 (0) < 0 .
Then we draw the same conclusion as (10).
Therefore, g 0 ( g − 1 1 (0)) ≈ 0 .
Combining all three cases above, we get δ > 0 .
Then applying Lemma 8 we complete the proof.
A.2. C OMPARISON BETWEEN UFL AND CFL
In this section, we compare the performance of UFL and CFL.
In Lemma 10 and Lemma 11, we illustrate the conditions for UFL to have the same performance as CFL.
In Lemma 12, Lemmaand Lemma 14, we illustrate the scenarios when CFL outperforms UFL.
To do the comparison, ﬁrst we introduce some additional notations.
Deﬁne the accuracy of a classiﬁer f as
[Equation]
Given the required global demographic disparity ε , deﬁne the performance of f UFL ε 0 ,ε 1 as:
[Equation]
and deﬁne performance of f CFL ε as:
[Equation]
Now we are able to compare the performance between UFL and CFL with the metric UFL ( ε 0 , ε 1 ; ε ) and CFL ( ε ) .
In particular, we will show that, under some mild conditions, max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) <
CFL ( ε ) , which implies the gap between UFL and CFL is inevitable.
We begin with the following two lemmas, which describe the cases that UFL ( ε 0 , ε 1 ; ε ) =
CFL ( ε ) .
Lemma 10.
Let q ∈ Given an UFL classiﬁer f UFL ε 0 ,ε 1 such that DP Disp ( f UFL ε 0 ,ε 1 ) ≤ ε and a CFL classiﬁer f CFL ε , we have UFL ( ε 0 , ε 1 ; ε ) ≤ CFL ( ε ) .
The equality holds if and only if λ UFL 0 ε= λ UFL 1 ε= λ CFL ε , where λ CFL ε is deﬁned in (5), λ UFL 0 ε, λ UFL 1 εare deﬁned in (6).
Proof.
The proof is straightforward.
Clearly, since f CFL ε is the optimizer to CFL( ε ), we have
UFL ( ε 0 , ε 1 ; ε ) ≤ CFL ( ε ) .
By Lemma 5, according to the form of the solution to CFL( ε ), f UFL ε 0 ,ε 1 is the solution to CFL( ε ) if and only if λ UFL 0 ε= λ UFL 1 ε= λ CFL ε .
Thus complete the proof.
Lemma 11.
Let q ∈ If the ERM is already fair, i.e. , ε ≥ | g (0) | , then
[Equation]
Proof.
Since the ERM is already fair, f CFL ε is ERM
=
(cid:74) η
( x ) > 1 / 2 (cid:75) .
Therefore, we take ε
=
ε 1 = 1 , and f UFL ε 0 ,ε 1 also equals to ERM.
Thus we conclude the lemma.
The next two lemmas describes the cases that UFL ( ε 0 , ε 1 ; ε ) < CFL ( ε ) .
Lemma 12.
Let q ∈ If g 0 (0) g 1 (0) < 0 , max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) < CFL ( ε ) for all ε < | g (0) | .
Proof.
In this proof, we only consider the case that g 1 (0) > 0 , | g 1 (0) | ≥ | g 0 (0) | .
The proof for g 1 (0) > 0 or | g 1 (0)
| ≥ | g 0 (0) | is similar.
Next, we divide the proof into two cases.
Case 1.
max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) = 0 : UFL cannot achieve ε global demographic disparity.
The conclusion holds
Case 2.
max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) > 0 : UFL can achieve ε global demographic disparity.
Since ε < | g (0) | , by Lemma 7, we have λ CFL ε (cid:54) = 0 .
Next, we solve f UFL ε 0 ,ε 1 by solving the local version of CFL( ε ).
Combining Lemma 7, g 1 (0) > 0 and g 0 (0) < 0 yields λ UFL 0 ε≥ 0 , λ UFL 1 ε≤ 0 .
If λ UFL 0 ε= λ UFL 1 ε, then λ UFL 0 ε= λ UFL 1 ε= 0 (cid:54) =
λ CFL ε .
Thus, we conclude the lemma by applying
Lemma 10.
Remark 6.
Lemma 12 implies that if ERM is favoring different groups in different clients, there exists an inevitable gap between the performance of UFL and that of CFL.
Lemma 13.
Let q ∈
Let τ =
min (cid:8) | g (0) | , max { sign( g (0))
g ( g − 1 0 (0)) , sign( g (0))
g ( g − 1 1 (0)) } (cid:9) .
If g 0 (0) g 1 (0) > 0 , we have
[Equation]
for all
[Equation]
o.w .
Proof.
Without any loss of generality, assume g 0 (0) , g 1 (0) > 0 .
Then by Lemma 7, we have λ UFL 0 ε≤ 0 , λ UFL
1 ε≤ 0 for all ε 0 , ε 1 ∈ [0 , 1] , and g (0) =
( g 0 (0) + g 1 (0)) / 2 >
To study the performance of UFL when g 0 (0) g 1 (0) < 0 , recall that we use f ε i i to denote the local classiﬁer trained by client i in UFL analysis.
Therefore, f
i is the local classiﬁer trained by client i that achieves perfect local fairness.
Next, we discuss two cases to prove the result.
In Case 1, we will show that τ = 0 , and then prove that max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) =
CFL ( ε ) ; in Case 2, we will show that τ > 0 , and then prove that max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) <
CFL ( ε ) when ε < τ .
Case 1.
f 0
= f 0 1 : the two local classiﬁers that achieve perfect local fairness are equal.
When ε ≥ g (0) , the conclusion holds by directly applying Lemma 11.
Therefore, in what follows, we focus on the case that ε < g (0) .
Next, we will ﬁrst, show that when ε = 0 , λ UFL 0= λ UFL 1= λ CFL0 , which implies that f 00 = f
=
f CFL0 .
Since f 00 = f 01 , we have λ UFL 0= λ UFL 1, and thus g − 1 0 (0) =
g − 1 1 (0) .
Consequently, we get g[-( λ UFL 
-]
[Equation]
UFL[-
-]
[Equation]
By the monotonicity of g , we have λ UFL 0= λ
[Equation]
1= λ CFL0 and τ = 0 .
Next, we will show that, for ε (cid:54) =
, there also exists ε 0 , ε 1 ∈ [0 , 1] such that λ UFL 0 ε= λ UFL 1 ε= λ CFL ε , which implies f UFL 0 ε= [Equation] = f [Equation]
Consider ε (cid:54) = 0 .
Select ε i
=
g i ( λ CFL ε ) , i = 0 , 1 .
By Lemma 5 and the monotonicity of g , we have λ CFL0 < λ CFL ε < 0 .
Therefore, ε i =
g i ( λ CFL ε ) >
g i ( λ CFL0 ) = 0 .
By Lemma 5, we get λ UFL i ε i =
g − 1 i ( ε i ) for i = 0 , 1 .
By the selection of ε i , we have λ CFL ε =
g − 1 i ( ε i ) .
Therefore, λ CFL ε = λ UFL 0 ε= λ UFL 1 εwhen ε (cid:54) = 0 .
Combining all the discussion above yields f UFL ε 0 ,ε 1 = f CFL ε for all ε < g (0) , thus we conclude max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) =
CFL ( ε ) for all ε < g (0) .
Consequently, the lemma holds under Case 1.
Case 2.
f 00 (cid:54) =
f 01 : the two local classiﬁers that achieve perfect local fairness are different.
The key idea of this proof is: when MD 0 ( f CFL ε ) , MD 1 ( f CFL ε ) ≥ 0 , then we can always select ε 0 = g 0 ( λ CFL ε ) =
MD 0 ( f CFL ε ) > 0 , ε 1 = g 1 ( λ CFL ε )
=
MD 1 ( f CFL ε ) > 0 such that λ UFL 0 ε= g − 1 0 ( ε 0 )
=
λ CFL ε and λ UFL 1 ε= g − 1 1 ( ε 1 ) =
λ CFL ε , thus f UFL ε 0 ,ε 1 = f CFL ε ;
when
MD 0 ( f CFL ε ) MD 1 ( f CFL ε ) =
g {+
+}
( λ CFL ε ) g 1 ( λ CFL ε ) < 0 , however, by Lemma 7, for all ε 0 , ε 1 ∈ [0 , 1] × [0 , 1] , we have g 0 ( λ UFL 0 ε) g 1 ( λ UFL 1 ε) > 0 > g 0 ( λ CFL ε ) g 1 ( λ CFL ε ) , thus there exist i ∈ { 0 , 1 } such that λ UFL i ε i (cid:54)
= λ CFL ε and f UFL ε 0 ,ε 1 (cid:54) =
f CFL ε .
Next, we will give rigorous proof.
Since f 00 (cid:54) =
f 01 , we have λ UFL 0(cid:54)
= λ UFL 1.
By Lemma 5, we get g − 1 0 (0) (cid:54) =
g − 1 1 (0) .
Without any loss of generality, assume g − 1 0 (0) <
g − 1 1 (0) , which implies g 1 ( g − 1 0 (0))
<
g 1 ( g − 1 1 (0)) =
and g 0 ( g − 1 0 (0))
= 0 <
g 0 ( g − 1 1 (0)) .
Thus we get g 1 ( g − 1 0 (0))
< 0 < g 0 ( g − {+
 [Equation]+}
Combining the inequality above and g = g 0 + g 1yields
[Equation]
Thus we have
[Equation]
When ε ≥ | g (0) | , by Lemma 11, clearly we have max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) =
CFL ( ε ) .
For the other case ε < | g (0) | , by Lemma 7 we have λ = g − 1 ( ε ) .
Similar to Case 1, in order to achieve λ UFL 0 ε= λ UFL 1 ε= λ CFL ε , we select ε i =
g i ( λ CFL ε ) .
When ε < g ( g − 1 1 (0)) , [Equation] CFL
[Equation]
Since g 1 (0) > 0 , by Lemma 7 we have g 1 ( λ UFL 1 ε) ≥ 0 , from the monotonicity of g 1 we conclude λ UFL 1 ε(cid:54) =
λ CFL ε .
By Lemma 10, we have max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) <
CFL ( ε ) for all ε ≤ τ .
When ε ≥ g ( g − 1 1 (0)) , applying (11) we have
[Equation]
where the ﬁrst inequality comes from Case 1.
Thus, λ i = g − 1 ( ε i ) =
λ as desired, and we obtain f UFL ε 0 ,ε 1 = f CFL ε .
Combining both cases above yields the desired conclusion.
Remark 7.
Recall that we use f ε i i to denote the local classiﬁer trained by client i in UFL analysis.
In the expression of τ : [Equation]
| g (0) | is the demographic disparity of ERM, sign( g (0)) g ( g − 1 0 (0)) is the demographic disparity of local classiﬁer f 00 , and sign( g (0))
g ( g − 1 1 (0)) is the demographic disparity of local classiﬁer f 01 .
According to the proof of Lemma 13, we obtain max { sign( g (0))
g ( g − 1 0 (0)) , sign( g (0))
g ( g − 1 1 (0)) } >
if and only if two local classiﬁers which achieves perfect local fairness is equal, i.e. , f 00 = f 01 .
Therefore, Lemma 13 implies that, if the ERM is favoring the same group on different clients and the two local classiﬁers which achieve perfect local fairness are unequal, then UFL performs strictly worse than CFL when the required demographic disparity is smaller than a certain value.
So far we assume a ∼ Bern( q ) for both client 0 and client 1.
When both clients do not share the same q , we can conclude that CFL outperforms UFL in the following lemma.
Lemma 14.
Assume a ∼ Bern( q i ) in client i , and q(cid:54) =
q∈ (0 , 1) .
Then max ε 0 ,ε 1 UFL ( ε 0 , ε 1 ; ε ) <
CFL ( ε ) for all ε <
| g (0) | .
Proof.
We assemble the dataset from two clients to have x | a = a ∼ P a =
[Equation]
a = 0 , 1 .
We let f CFL ε be the solution to CFL( ε ), with q = q 0 + q 1 2 : f CFL ε = (cid:74) s ( x, a ) > 0 (cid:75) , where s ( x, 0)
=
2 η ( x ) − 1 + λ CFL ε− q , s ( x, 1) =
2 η ( x ) − 1 − λ CFL ε q .
Given an UFL classiﬁer f UFL ε 0 ,ε
=
( f ε 0
+ f ε 1 1 ) / 2 such that DP Disp ( f UFL ε 0 ,ε 1 ) ≤ ε , the solution reads
[Equation]
, where s i ( x, 0) = 2 η [Equation] x )
[Equation]
We prove the lemma by contradiction argument.
If Acc ( f UFL ε 0 ,ε 1 ) =
CFL ( ε ) , then f UFL ε 0 ,ε 1 is a solution to CFL( ε ) with q = q 0 + q 1 2 .
Since ε < | g (0) | , by Lemma 7 we have λ CFL ε (cid:54) = 0 .
Without any loss of generality, assume λ CFL ε < 0 .
Below we discuss three cases.
Case 1.
λ UFL 0 ε= λ UFL 1 ε= 0 : the UFL classiﬁer is ERM.
In this case, f ε 0= f ε 1 1 .
We have f UFL ε 0 ,ε 1 ( x, 0)
= 1 for η ( x ) > 12 , and f CFL ε = 0 for η ( x ) <
(1 − λ CFL ε / (1 − q )) / 2 .
By Lemma 6, f UFL ε 0 ,ε 1 is not a solution to CFL( ε ).
Case 2.
λ UFL 0 ε(cid:54)
= 0 or λ UFL 1 ε(cid:54)
= 0 , and λ UFL [Equation] λ UFL 1 ε= 0 : the UFL classiﬁer is not ERM, but one of the local classiﬁer is ERM.
Without any loss of generality, let λ UFL 0 ε= 0 , λ UFL 1 ε< 0 .
Then f ε 0 0 ( x, 0)
= 1 for η ( x ) > 12 , while f ε 1 1 ( x, 0)
=
for η ( x ) < (1 − λ UFL 0 ε(1 − q 1 )) / 2 .
Thus we get
[Equation]
By Lemma 6, f UFL ε 0 ,ε 1 is not a solution to CFL( ε ).
Case 3.
λ UFL 0 ελ UFL 1 ε(cid:54)
=
: The local classiﬁers are not ERM.
When λ UFL 0 ε 0 1 − q 0 (cid:54) = λ UFL 1 ε 1 1 − q 1 , without loss of generality, let λ UFL 0 ε 0 1 − q 0 > λ UFL 1 ε 1 1 − q 1 .
Then by the same argument in
Case 2, we have
[Equation]
By Lemma 6, f UFL ε 0 ,ε 1 is not a solution to CFL( ε ).
When λ UFL 0 ε 0 q 0 (cid:54) = λ UFL 1 ε 1 q 1 , similarly, f UFL ε 0 ,ε 1 is not a solution to CFL( ε ).
When λ UFL 0 ε 0 q 0 = λ UFL 1 ε 1 q 1 and λ UFL 0 ε 0 1 − q 0 = λ UFL 1 ε 1 1 − q 1 , since λ UFL 0 ελ UFL 1 ε(cid:54) = 0 , we have qλ UFL 0 ε= qλ UFL 1 ε, 1 − qλ UFL 0 ε= 1 − qλ UFL 1 ε, which leads to 1 λ UFL 0 ε= 1 λ UFL 1 εand thus q 0 = q 1 .
This contradicts with the assumption that q 0 (cid:54) = q 1 .
Combining all three cases yields desired conclusion.
A. FFL VIA F ED A VG ANALYSIS
In this section, we analyze FFL via F ED A VG for the case of two clients. For purpose of illustration, with I = 2 , we denote f FFL via FedAvg ε 0 ,ε= f FFL via FedAvg ε to be the solution to FFL via F ED A VG ( ε ) .
In Sec.
A.3.1, we present a formal version of Thm. 3 and show that compared to UFL, FFL via F ED A VG has strictly higher fairness.
In Sec.
A.3.2 we derive the solution to FFL via F ED A VG ( ε ) , and show it is equivalent to FFL via F ED A VG .
In Sec.
A.3.3, we analyze the limitation of FFL via F ED A VG and present a formal version of Lemma 4.
A.3. I MPROVE FAIRNESS VIA FEDERATED LEARNING
Different to UFL, FFL via F ED A VG can reach any ε demographic disparity:
Theorem 15 (Formal version of Thm.
3 under two clients cases) .
Let q ∈ For all ε ∈ [0 , 1] , there exists ε 0 , ε 1 ∈ [0 , 1] such that DP Disp ( f FFL via FedAvg ε 0 ,ε) ≤ ε .
Thus under the condition in Lemma 8, we have
[Equation]
Proof.
For any ε ∈ [ [Equation] [Equation] let ε
= ε 1 = ε .
Then the global DP disparity becomes
[Equation]
A.3. T HE BEST CLASSIFIER OF FFL VIA F ED A VG
For FFL via F ED A VG , we directly consider multi-client cases.
To visualize the gap between UFL,
FFL via F ED A VG , and CFL, in our numerical experiments, we draw ﬁnite samples from Gaussian distribution, and then we optimize the empirical risk with the fairness constraint to obtain the classiﬁer trained by FFL via F ED A VG .
The following lemma provides the solution to FFL via F ED A VG ( ε ) when X is ﬁnite.
Lemma 16.
For ﬁnite X , the solution to FFL via F ED A VG ( ε ) is given by
[Equation]
where s i ( x, a ) = 2 η ( x ) − 1 + Iλ i (cid:74) a=0 (cid:75) 1 − q −
Iλ i (cid:74) a=1 (cid:75) q , for certain λ 0 , . . .
λ I − 1 ∈ R .
Proof.
This proof is based on Menon & Williamson (2018).
The key idea of this proof is to use the Lagrangian approach.
Before we applying the Lagrangian approach, we will show that FFL via
F ED A VG ( ε ) is expressible as a linear program, and thus the strong duality holds.
Since X is ﬁnite, f is a vector of ﬁnite dimension.
Based on the proof of Lemma 5, the error rate can be written as
[Equation]
and the fairness constraints can be written as
[Equation]
for i ∈ [ I ] .
Let u ( x, a ) =
(1 − 2 η ( x )) P (x = x, a = a ) , u (cid:48)
=
P (y = 1) , and v i ( x, a )
= ( (cid:74) a = 0 (cid:75) − (cid:74) a = 1 (cid:75) )
P (x = x | a = a, i = i ) / P (a = a ) , for x ∈ X , a ∈ A , i ∈ [ I ] .
Note that u, v 0 , v 1 are vectors of the same dimension of f .
For ease of notation, we allow ≤ to be applied to pairs of vectors in an element-wise manner.
Therefore, the optimization is
[Equation]
which is a linear objective with linear constraint.
Therefore, the strong duality holds for FFL via
F ED A VG ( ε ) .
Next, we apply Lagrangian approach to solve the FFL via F ED A VG ( ε ) .
Recall that
[Equation]
and
[Equation]
By strong duality, for λ (cid:48) 0 , . . , λ (cid:48) 2 I − 1 ≥ 0 , the corresponding Lagrangian version of FFL via F ED A VG ( ε ) is [Equation]
[Equation] i = i
[Equation]
(cid:105)
Let λ [-
-]i
= λ (cid:48) 2 i − λ (cid:48) 2 i +1 , i ∈ [ I ] , then we get (12) = min
[Equation]
∈F
[Equation]
x ∼P
[Equation]
i
[Equation]
a (cid:20)
I f (x
[Equation]
a)(1 −
[Equation]
(x
[Equation]
) − (cid:88)
i
[Equation]
[ I ] (cid:16)
[Equation]
(x
[Equation]
0) (cid:74)
[Equation]
0 (cid:75)
[Equation]
where s i is deﬁned in Lemma 16.
Thus the above equation reaches its minimum at
[Equation]
Remark 8.
Based on the proof of Lemma 16, FFL via F ED A VG ( ε ) is equivalent to solving
[Equation]
Under certain conditions (assumptions 1 to 4 in Li et al.
(2020b))
, we have solving FFL via
F ED A VG ( ε ) is equivalent to minimizing
[Equation]
locally and applying F ED A VG (Theorem 1 in Li et al. (2020b)).
A.3. C OMPARISON OF FFL VIA F ED A VG AND CFL
Lemma 17 (Formal version of Lemma 4 under two clients cases) .
When a | i = 0 ∼ Bern(0) , a | i = 1 ∼ Bern(1) and DP Disp ( f CFL) > 0 , we have
[Equation]
Proof.
Since a | i = 0 ∼ Bern(0) , a | i = 1 ∼ Bern(1) , the constraints in FFL via F ED A VG ( ε ) vanish.
When ε = 1 , the constraint in CFL( ε ) always holds and thus also vanishes.
Thus in such scenario the solution to FFL via F ED A VG ( ε ) becomes f CFL.
Then from the assumption we have
DP Disp ( f FFL via FedAvg ε 0 ,ε) = DP Disp ( f CFL) > DP Disp ( f CFL) = 0 .
A. E XTENSION TO MULTI - CLIENT CASES
In this subsection, we perform the analysis of UFL and FFL via F ED A VG for the multi-client cases.
We present a more general version of Lemma 8, Thm. 15 and Lemma 17.
The following lemma shows the fundamental limitation of UFL:
Lemma 18 (Formal version of Lemma 1) .
Let q ∈
Consider a partition which divides I clients into two subsets.
Denote the mixture distribution of each subset as x | a = a, j = j ∼ ˜ P ( j ) a , where j is the index of the subset, and ˜ P
( j ) a is a distribution, for a, j = 0 , 1 .
Similar to two clients case, deﬁne ˜
g j ( λ ) =
(cid:82) [ η − 1 ( 12 − λ 2(1 − q ) ) , + ∞ )
d ˜ P ( j ) 0 − (cid:82) [ η − 1 ( 12 + λ 2 q ) , + ∞ )
d ˜ P ( j ) 1 .
Consider the case that q i = q for all i ∈
[ I ] and q ∈ (0 , 1) .
Denote the proportion of the two subset as J 0 and J 1 , where J 0 , J 1 > 0 and J 0 + J 1 = 1 .
Let c = min {| ˜ g 0 (0) | , | ˜ g 1 (0) |} .
Deﬁne ˜ ψ : [0 , c ] × [0 , c ] → [ − 1 , 1] as
[Equation]
If there exists a partition such that ˜ g 0 (0)˜ g 1 (0) < 0 and ˜ ψ (˜ ε 0 , ˜ ε 1 )(˜ g 0 (0) + ˜ g 1 (0))
>
for all ˜ ε 0 , ˜ ε 1 ∈ [0 , c ] , then for all ˜ ε 0 , ˜ ε 1 ∈
[Equation]
Proof.
By Lemma 8, we conclude the achievable fairness range of UFL is strictly smaller than that of CFL.
Therefore, pooling the datasets in one subset and perform fair learning can clearly achieve a wider range of fairness than perform fair learning on each client individually.
Thus, we can consider the two subsets as two clients with uneven amounts of data, which is almost the same case Lemmaconsiders.
Therefore, we follow the same proof idea as Lemma 8 to prove our claim.
Denote the assembled classiﬁer trained from two pooled datasets as ˜ f UFL ˜ ε 0 , ˜ ε 1 .
Note that the mean difference can be expressed as
[Equation]
In the following proof, we will show, the mean difference cannot reach 0.
Without any loss of generality, assume | ˜ g 0 (0) | < | ˜ g 1 (0) | and ˜ g 1 (0) > 0 .
By ˜ g 0 (0)˜ g 1 (0) < 0 and ˜ ψ (˜ ε 0 , ˜ ε 1 )(˜ g 0 (0) + ˜ g 1 (0)) > 0 for all ˜ ε 0 , ˜
ε 1 ∈ [0 , c ] , we have ˜ g 0 (0) < 0 and ˜ ψ
(˜ ε 0 , ˜ ε 1 ) > 0 for all ˜ ε 0 , ˜ ε 1 ∈ [0 , c ] .
Without any loss of generality, assume J 0 ≤ J 1 .
First, we will prove that UFL achieves its lowest mean difference when ˜ ε 0 , ˜ ε 1 ∈ [0 , c ] .
In what follows, we consider ﬁve different cases to derive the desired result.
[Equation]
on both clients.
By (6), we have ˜ λ UFL 0 ˜ ε= ˜ λ [Equation] = 0 .
Recall ˜ g
i ( · ) is a monotone increasing function, combine ˜ g 1 (0) > 0 and Lemma 7, and thus ˜ g
(˜ g − 1 1 (0)) <
˜ g 0 (0) < 0 .
Applying the above conclusion yields
[Equation]
Applying (6) results in λ UFL 1 ε= 0 .
By the fact that ˜ g i ( · ) is a strictly monotone increasing function, we have ˜ λ UFL [Equation] = [Equation]
g
[Equation]
−
[Equation]
) >
[Equation]
˜ g
[Equation]
= 0 .
Applying the above conclusion yields
[Equation]
In the ﬁrst equality we used ˜ λ UFL 0 ˜ ε
[Equation]
Case 3.
˜ ε
[Equation]
≤
[Equation] g [Equation] ) | : ERM is unfair on both client 0 and client 1.
Applying (6) we have ˜ λ UFL 0 ˜ ε
[Equation] [Equation]
˜ [Equation]
Then we have
[Equation]
Case 4.
˜ ε 0 > | ˜ g 0 (0) | , ˜ ε 1 ≤ | ˜ g 0 (0) | : ERM is fair on client 0 and very unfair on client 1.
By (6), we have ˜ λ UFL 0 ˜ ε= 0 , ˜ λ
[Equation]
=
˜ g − 1 1 (˜ ε 1 ) > ˜ g − 1 1 (0) .
Then we obtain (
[Equation]
Case 5.
˜ ε 0 > | ˜ g 0 (0) | , | ˜ g 0 (0) | ≤ ˜ ε 1 < | ˜ g 1 (0) | : ERM is fair on client 0 and unfair on client 1.
Applying (6) implies ˜ λ UFL 1 ˜ ε= ˜ g − 1 1 (˜ ε 1 ) >
˜ g − 1 1 (0) .
Therefore,
[Equation]
Combining all the cases above, we conclude that when ˜ g 1 (0) > 0 , DP Disp ( ˜ f UFL ˜ ε 0 , ˜ ε 1 ) ≥ ˜ δ
= min {| ˜ ψ
(˜ ε 0 , ˜ ε 1 ) | : ˜ ε 0 , ˜ ε 1 ∈ [0 , c ] } > 0 for all ˜ ε 0 , ˜ ε 1 ∈ [0 , 1] .
Remark 9.
Based on the proof above, we can conclude, for the cases with multiple clients, the fundamental limitation of UFL still exists.
The following theorem shows that FFL via F ED A VG can reach any ε DP disparity:
Theorem 19 (Generalized version of Thm. 15) .
Let q i = q ∈
(0 , 1) for all i ∈ [ I ] .
For all ε ∈ [0 , 1] , let ε i ≤ ε for all i ∈
[ I ] , then DP Disp ( f ε ) ≤ ε .
Thus under the condition in Lemma 18, we have
[Equation]
Proof.
When ε i ≤ ε the global DP disparity becomes
[Equation]
The following theorem shows the limitation of FFL via F ED A VG :
Lemma 20 (Generalized version of Lemma 17) .
Let a |
i
= i ∼ Bern(0) or a | i
= i ∼ Bern(1) for all i ∈
[ I ] .
When DP Disp ( f CFL) > 0 , we have
[Equation]
Proof.
Since a | i = i ∼ Bern(0) or a | i
= i ∼ Bern(1) , the constraints in (FFL via F ED A VG ( ε ) ) vanish.
When ε = 1 , the constraint in CFL( ε ) always holds and thus also vanishes.
Thus in such scenario the solution to (FFL via F ED A VG ( ε ) ) becomes f CFL.
Then from the assumption we have
[Equation] f
[Equation] [Equation]
PPENDIX - F ED FB ANALYSIS AND ALGORITHM DESCRIPTION
In this section, we provide our bi-level optimization formulation for F ED FB for four fairness notions: demographic parity, equal opportunity, equalized odds and client parity, and design the corresponding update rule.
This development can also be applied to centralized case.
Then, we provides more details of how we incorporate FB with federated learning.
To explain how to optimize the weights of different groups, we introduce some necessary notations ﬁrst.
Denote the k th sample as (x k , y k , a k , i k ) , k = 1 , . . . , n .
Here x k ∈ X is the input feature, y k ∈ { 0 , 1 } is the label, a k ∈ A =
[ A ] is the sensitive attribute and
i k ∈
[ I ] is the index of the client that the sample belongs to.
A represents the total amount of sensitive attribute and I represents the total amount of clients.
Denote the number of samples in group a as n (cid:63),a := |{ k : a k = a }| .
Let n y,a :=
|{ k : y k
= y, a k = a }| be the number of samples in group a of label y , and n ( i ) y,a :=
|{ k : y k
= y, a k = a, i k
= i }| be the number of samples belong to client i of label y and sensitive attribute a .
Deﬁne the loss function as (cid:96) (y , ˆy) .
Let L y,a ( w ) be the empirical risk aggregated over samples subject to y
=
y, a = a , i.e. , L y,a ( w ) :
= (cid:80) k :
y k
= y, a k = a (cid:96) (y k , ˆy k ) /n
y,a , where n y,a := |{ k : y k
= y, a k = a }| .
We then deﬁne the local version of L y,a as L ( i ) y,a ( w ) :
= (cid:80) k :
y k
= y, a k = a, i k
= i (cid:96) (y k , ˆy k ) /n
( i ) y,a .
B. F ED FB w.r.t DEMOGRAPHIC PARITY
To extend Roh et al.
(2021) to multiple groups cases, we propose a different bi-level optimization problem w.r.t demographic parity.
This development can also be applied to the centralized setting.
The following proposition gives a necessary sufﬁcient condition for demographic parity, which can be directly obtained from Roh et al.
For completeness, we also include the proof here.
Proposition 21 (Necessary sufﬁcient condition for demographic parity, Proposition 2 in Roh et al.
Consider 0-1 loss: (cid:96) (y , ˆy) =
(cid:74)
y (cid:54) =
ˆy (cid:75) .
Let L (cid:48)
y,a ( w ) :
= n y,a n (cid:63),a L y,a ( w ) , then
[Equation]
(14) for all a ∈ [ A ] is a necessary sufﬁcient condition for demographic parity.
Proof.
We denote by P the empirical probability.
The demographic parity is satisﬁed when P (ˆy = 1 | a = 0)
=
P (ˆy = 1 | a = a ) holds for all a ∈ [ A ] .
Thus,
[Equation]
For 0-1 loss, we have (cid:96) ( | 1 − y | , · ) = 1 − (cid:96) ( y, · ) , thus
[Equation]
By replacing (cid:80) k :y
[Equation]
= y
[Equation] a (cid:96) (y k , ˆy k ) =
n y,a L y,a ( w ) , we have
[Equation]
Remark 10.
Proposition 21 provides us a way to measure demographic disparity using group-speciﬁc losses.
However, since 0-1 loss is noncontinuous, in practice, we use the “continuous surrogate” of it, which is cross entropy.
The necessary sufﬁcient condition for demographic parity (14) inspires us to achieve demographic parity by connecting one group with all the other groups for non-binary sensitive attribute settings.
To achieve demographic parity, we introduce another parameter: λ
= ( λ 0 , . . .
, λ A − 1 ) , the weights attached to samples.
We formalize the reweighting task into the following bi-level optimization problem, where the outer objective function captures the demographic parity criterion:
[Equation]
where Λ = [0 , 2 n (cid:63) [Equation] [Equation] ] × · · · × [0 , 2 n
[Equation]
We make the following assumption to our loss function to have the decreasing direction in Lemma 22.
Assumption 1.
L (cid:48)
y,a ( · ) is twice differentiable for all y ∈ { 0 , 1 } , a ∈ [ A ] , and
[Equation]
If L (cid:48)
y,a ( w λ ) is convex for all y ∈ { 0 , 1 } , a ∈ [ A ] , the condition (16) holds unless for all a ,
L (cid:48) 0 ,a ( · ) , L (cid:48) 1 ,a ( · ) share their stationary points, which is very unlikely (see Remark 1 in Roh et al.
The following lemma provides a decreasing direction of the outer objective function F dp , which inspired us to design the update rule of λ .
Lemma 22 (Decreasing direction of F dp ) .
If Assumption 1 holds, then on the direction µ ( λ ) =
( µ 0 ( λ ) , . . .
, µ A − 1 ( λ ))
where
[Equation]
for all a ∈ { 1 , . . .
, A − 1 } , we have µ ( λ ) · ∇ F dp ( λ ) ≤ 0 , and the equality holds
if only if µ ( λ ) = 0 .
Proof.
We compute the derivative as
[Equation]
Note that w λ is the minimizer to (15) inner , we have
[Equation]
We take the λ j derivative to the above equation and have
[Equation]
Thus we get ∂ w λ
[Equation]
Then on the direction µ ( λ ) given by (17)
[Equation]
we combine (18) and (19) to have
[Equation]
where we have used Assumption 1, and the equality holds only when µ ( λ )
= 0 .
Inspired by Lemma 22, in each communication round t = 0 , 1 , . .
. , we design update rule for λ as:
[Equation]
where α t is the step size.
Now we introduce how clients collaborate to solve the bi-level optimization problem (15).
First, we focus on the outer objective function (15) outer and introduce how clients collaborate to update the weight λ .
Note that the central server can compute L (cid:48)
y,a ( w λ ( t ) ) by weight-averaging the local group loss L ( i ) y,a ( w λ ( t ) ) sent from clients at communication rounds as [Equation] thereby obtain µ ( λ ( t ) ) and update λ ( t ) by (20).
Next, we focus on the inner objective function (15) inner and introduce how clients collaborate to update the model parameters w λ using F ED A VG .
Note that we can decompose the objective function L ( w , λ ) into L ( w , λ ) =
(cid:80)
i ∈
[ I ] L ( i ) ( w , λ ) , where L ( i ) ( w , λ ) :
= (cid:80) A − 1 a {+=
+}
[ λ a n ( i ) 0 ,a L ( i ) 0 ,a /n (cid:63),a + (2 n (cid:63),a n − λ a ) n ( i ) 1 ,a L ( i ) 1 ,a /n (cid:63),a ] is the client objective function of client i .
The global objective can be seen as a weighted sum of the client objective function.
Therefore, we can use F ED A VG to solve the inner optimization problem.
We present the pseudocode of F ED FB w.r.t demographic parity in Algorithm 2. Algorithm
Server executes: [Table] ; for each iteration t = 1 , 2 , . . . do Clients
[Table]
updates;
[Table]
{+a + n 0 , 0 n (cid:63), 0 − n 0 ,a n (cid:63),a (cid:17) ; µ a ← − L (cid:48) 0 , 
+}
+ L (cid:48) 1 , 0 + L (cid:48) 0 ,a − L (cid:48) 1 ,a + n 0 , 0 n (cid:63), 0 − n 0 ,a n (cid:63),a , a ∈ [ A ] \{ 0 } ; λ
[Table]
, for all
[Table]
Broadcast w λ and λ to clients; endoutput : w λ
ClientUpdate ( i, w , λ ) : w [Equation] Gradient descent w.r.t objective function
[Equation]
Send w ( i ) , L ( i ) 0 ,a ( w ) , L ( i ) 1 ,a ( w ) for all a ∈ [ A ] to server via a SecAgg protocol;
Next, we analyze the convergence performance of F ED FB.
We need to make the following assumptions on the objective function L ( i ) ( w , λ ) , i ∈
[ I ] .
For simplicity, we drop the λ here and use the notations L ( i ) ( w ) and L ( w ) instead.
We use w ( i ) t to denote the model parameters at t -th iteration in i -th client.
The assumptions below are proposed by work Li et al.
(2020b):
Assumption 2 (Strong convexity, Assumption 1 in Li et al.
(2020b)) .
L ( i ) ( w ) is µ -strongly convex for i ∈
[ I ] , i.e. , for all v and w , w , L ( i ) ( v ) ≥ L ( i ) ( w ) + ( v − w ) (cid:62) ∇ L ( i ) ( w ) + µ 2 (cid:107) v − w (cid:107) 22 .
Assumption 3 (Smoothness, Assumption 2 in Li et al.
(2020b)) .
L ( i ) ( w ) is L -smooth for i ∈
[ I ] , i.e. , for all v and w , L ( i ) ( v ) ≤ L ( i ) ( w ) + ( v − w ) (cid:62) ∇ L ( i ) ( w ) + L 2 (cid:107) v − w (cid:107) 22 .
Assumption 4 (Bounded variance, Assumption 3 in Li et al.
(2020b)) . Let ξ ( i ) t be sampled from i -th device’s local data uniformly at random, where t ∈ [ T ] , and T is the total number of every client’s SGDs.
The variance of stochastic gradients in each device is bounded: [Equation] < [Equation]
i ∈
[ I ] .
Assumption 5 (Bounded gradients, Assumption 4 in Li et al.
(2020b)) . The expected squared norm of stochastic gradients is uniformly bounded, i.e. , E (cid:13)(cid:13)(cid:13) ∇ L ( i ) ( w ( i ) t , ξ ( i ) t ) (cid:13)(cid:13)(cid:13) < ∞ for all i ∈
[ I ] , t ∈ [ T ] .
In F ED A VG , ﬁrst, the central server broadcasts the lastest model to all clients, then, every client performs local updates for a number of iterations, last, the central server aggregates the local models to produce the new global model(see Algorithm Description in Li et al.
(2020b)
for more detailed explanation).
We denote E as the number local iterations performed in a client between two communications, and
R be the total number of every client’s iteration.
Thus RE is the number of communications. With the above assumptions, the following theorem shows the convergence of FedFB in the case of two clients.
Theorem 23.
Consider the case of A = 2 .
Let Assumption 2, 3, 4, 5 on { L ( i ) ( · , λ ) }
i ∈
[ I ] and
Assumption 1 on { L (cid:48)
y,a ( · ) } y,a ∈{ 0 , 1 } hold.
Choose [Equation] such that
[Equation]
Suppose we use F ED A VG with R and E satisfying E 2 R → 0 to solve (15) inner between two λ update rounds.
We can ﬁnd sufﬁciently large T such that with high probability, applying update rule (20) leads to | λ ( T ) a
[Equation]
where λ (cid:63) is the local minimizer on direction µ ( λ ) .
Proof.
We ﬁrst derive the update rule in the case of A = 2 .
From (20), we have µ 0 = − µ 1 .
Denote
[Equation]
Then the update rule becomes
[Equation]
Then we apply F ED A VG with R number of total iterations to solve min w L ( w ; λ ( t ) ) , and obtain w ( t ) R .
Then in the update round from λ ( t ) to λ ( t +1) , by Thm. 1 in Li et al.
(2020b), we have
[Equation]
where w λ ( t ) =
arg min
w
L ( w ; λ ( t ) ) .
By Markov’s inequality, with probability 1 − δ ,
[Equation]
Then taking the union bound over T updating iterations of λ ( t ) , the conclusions above hold with probability at least 1 − Tδ for all λ ( t ) , t = 1 , 2 , · · · , T .
Therefore, with sufﬁciently large R = R ( δ ) such that E 2 δR → 0 , for all λ ( t ) in the T iteration, | L ( w ( t ) R ; λ ( t ) ) − L ( w λ ( t ) ; λ ( t ) ) | (cid:28) 1 , (cid:107) w ( t ) R − w λ ( t ) (cid:107) (cid:28) 1 .
By Lemma 22, F dp ( λ ) has a local minimizer λ (cid:63) on direction µ ( λ ) .
By update rule (21), we can ﬁnd large T > 0 to have
[Equation]
where a ∈ { 0 , 1 } .
Remark 11.
{+Note that Thm. 
+}
assumes F ED FB does not update λ in each communication round
and there are inﬁnite rounds of aggregations between two λ updating round.
However, for computation efﬁciency, we update λ at every communication round in practice.
B. F ED FB w.r.t EQUAL OPPORTUNITY
Similar to Proposition 21, we design the following bi-level optimization problems to capture equal opportunity:
[Equation]
Here Λ = { ( λ 1 , . . .
, λ A − 1 ) : λ 1 + · · · + λ A − 1 ≤ n 1 ,(cid:63) n , λ a ≥ 0 for all a = 1 , . . .
, A − 1 } .
For equal opportunity, we make the following assumption:
Assumption 6.
L y,a ( · ) is twice differentiable for all y ∈ { 0 , 1 } , a ∈ [ A ] , and
[Equation]
for all λ ∈ Λ .
With the above assumption, the following lemma provides the update rule:
Lemma 24.
If Assumption 6 holds, then on the direction
[Equation]
(23) we have µ ( λ ) · ∇ F eo ( λ ) ≤ 0 , and the equality holds
if only if µ ( λ ) = 0 .
Update rule for equal opportunity:
[Equation]
Proof of Lemma 24 .
We compute the derivative as
[Equation]
Note that w λ is the minimizer to (22)
[Equation]
we have
[Equation]
We take the λ j derivative to the above equation and have
[Equation]
Thus we get ∂ w λ
[Equation]
Then on the direction µ ( λ ) given by (23), we combine (24) and (25) to have
[Equation]
where we have used Assumption 6, the equality holds only when µ ( λ ) = 0 .
We present the F ED FB algorithm w.r.t equal opportunity in Algorithm 3.
Algorithm 3: F ED FB w.r.t Equal Opportunity
Server executes: input : Learning rate { α t } t ∈ N ;
Initialize λ a as n 1 ,a n for all a ∈ [ A ] \ { 0 } ; for each iteration t = 1 , 2 , . . .
do
Clients perform updates; w λ ← SecAgg (cid:8) w ( i ) (cid:9) for all i ;
L y,a ← SecAgg (cid:110) L ( i ) y,a (cid:111) for all y ∈ { 0 , 1 } , a ∈ [ A ] \ { 0 } ; µ a ← L 1 ,a − L 1 , 0 , a ∈ [ A ] \ { 0 } ; λ a ← λ a + α t (cid:107) µ (cid:107)
[Equation]
, for all a ∈ [ A ] \ { 0 } ; Broadcast w λ and λ to clients; endoutput : w λ
ClientUpdate ( i, w , λ ) : w ( i ) ← Gradient descent w.r.t objective function
[Equation] Send w ( i ) , L ( i )
[Equation]
( w ) , L ( i ) 1 ,a ( w ) for all a ∈ [ A ] to server via a SecAgg protocol;
B.
F ED FB w.r.t
For equalized odd, we design the following bi-level optimization problem: [Equation]
Here Λ [Equation] a
[Equation] [Equation] for all a = 1 , . . . , A − 1 } .
For equalized odds, we make the following assumption:
Assumption 7.
L y,a ( · ) is twice differentiable for all y ∈ { 0 , 1 } , a ∈ [ A ] , and
[Equation]
[Equation]
for all λ ∈ Λ .
With the above assumption, the following lemma provides the update rule:
Lemma 25.
If Assumption 7 holds, then on the direction µ ( λ ) =
( µ 0 , 1 ( λ ) , . . .
, µ 0 ,A − 1 ( λ ) , µ 1 , 1 ( λ ) , . . . , µ 1 ,A − 1 ( λ )) , with µ y,a (
[Equation]
=
[Equation]
(27) we have µ ( λ ) · ∇ F eod ( λ ) ≤ 0 , and the equality holds
if only if µ ( λ ) = 0 .
Update rule for equalized odd:
[Equation]
Proof of Lemma 25 .
We compute the derivative as
[Equation]
[Equation]
Note that w λ is the minimizer to (26) [Equation] we have
[Equation]
We take the λ y,j derivative to the above equation and have
[Equation]
Thus we get ∂
[Equation]
n
[Equation]
Then on the direction µ ( λ ) given by (27)
[Equation]
we combine (28) and (29) to have
[Equation]
where we have used Assumption [Equation] and the equality holds only when µ ( λ ) =
[Equation]
The full procedure is described in Algorithm 4. Algorithm
Server executes:
; Initialize
for
∈ iteration do Broadcast w and to clients; endoutput : w λ
ClientUpdate ( i, w , λ ) : w ( i ) ← Gradient descent w.r.t objective function (cid:80)
A − 1 a =1 (cid:16) λ 0 ,a L ( i ) 0 ,a ( w ) + λ 1 ,a L ( i ) 1 ,a ( w ) (cid:17) + ( n 0 ,(cid:63) n − (cid:80)
A − 1 a =1 λ 0 ,a ) L ( i ) 0 , 0 ( w ) + ( n 1 ,(cid:63) n − (cid:80)
A − 1 a =1 λ 1 ,a ) L i ) 1 , w
Send w
L to protocol;
B. F ED FB w.r.t CLIENT PARITY
For client parity, we slightly abuse the notation and deﬁne the loss over client i as L ( i ) ( w ) :
= (cid:80) i
k
= i (cid:96) (y k , ˆy k ) /n
( i ) , with n ( i ) =
|{ k : i
k = i }| .
Note that the L ( i ) ( w ) here is different from the one in Sec.
B.1.
We design the following bi-level optimization problem: min
[Equation]
Here
[Equation]
For client parity, we make the following assumption:
Assumption 8.
L ( i ) ( · ) is twice differentiable for all i = 1 , . .
, I − 1 , and
[Equation]
With the above assumption, the following lemma provides the update rule:
Lemma 26.
If Assumption 8 holds, then on the direction
[Equation]
we have µ ( λ ) · ∇ F cp ( λ ) ≤ 0 , and the equality holds
if and only if µ ( λ ) = 0 .
Then we update λ ( t ) =
( λ (1) ( t ) , . . .
, λ ( I − 1) ( t ) ) as follows:
Update rule for client parity:
[Equation]
i
[Equation]
[Equation]
[Equation]
I −
[Equation]
Proof of Lemma 26 .
We compute the derivative as
[Equation]
Note that w λ is the minimizer to (30)
[Equation]
we have
[Equation]
We take the λ ( j ) derivative to the above equation and have
[Equation]
Thus we get ∂ w λ
[Equation]
Then on the direction given by (31)
[Equation]
we combine (32) and (33) to have
[Equation]
where we have used Assumption 8, and the equality holds only when µ ( λ ) = 0 .
The Algorithm 5 gives the full description.
[Equation]
[Equation]
C A PPENDIX - E XPERIMENTS
We continue from Sec. 5 and provide more details on experimental settings, and other supplementary experiment results.
C. E XPERIMENT SETTING
The reported statistics are computed on the test set, and we set 10 communication rounds and 30 local epochs for all federated learning algorithms except A GNOSTIC F AIR .
We run 300 epochs for other methods.
For all tasks, we randomly split data into a training set and a testing set at a ratio of 7:3.
The batch size is set to be 128.
For all methods, we choose learning rate froom { 0 .
We solve F ED FB with sample weight learning rates α ∈ { 0 . 001 , 0 . 05 , 0 . 08 , 0 .
5 , 1 , 2 } in parallel and select the α which achieves the highest fairness. All benchmark models are tuned according to the hyperparameter conﬁguration suggested in their original works. We perform cross-validation on the training sets to ﬁnd the best hyperparameter for all algorithms. C. S YNTHETIC DATASET GENERATION
We generate a synthetic dataset of 5,000 examples with two non-sensitive attributes (x 1 , x 2 ) , a binary sensitive a , and a binary label y .
A tuple (x 1 , x 2 , y) is randomly generated based on the two Gaussian distributions: (x 1 , x 2 ) | y ∼ N ([ − 2; − 2] , [10 , 1; 1 , 3]) and (x 1 , x 2 ) | y
= 1 ∼ N ([2; 2] , [5 , 1]) , where y ∼ Bern(0 . 6) .
For the sensitive attribute a , we generate biased data using an unfair scenario p x 1 , x 2 ((x (cid:48) 1 , x (cid:48) 2 ) | y = 1) /
[ p x 1 , x 2 ((x (cid:48) 1 , x (cid:48) 2 ) | y = 0)
+ p x 1 , x 2 ((x (cid:48) 1 , x (cid:48) 2 ) | y
= 1)] , where p x 1 , x 2 is the pdf of (x 1 , x 2 ) .
We split the data into three clients in a non-iid way.
We randomly assign 50% , 30% , 20% of the samples from group 0 and 20% , 40% , 40% of the samples from group 1 to 1st, 2nd, and 3rd client, respectively.
To study the empirical relationship between the performance of F ED FB and data heterogeneity, we split the dataset into other ratios to obtain the desired level of data heterogeneity.
To get the dataset with low data heterogeneity, we draw samples from each group into three clients in a ratio of 33% , 33% , 34% and 33% , 33% , 34% .
For dataset with high data heterogeneity, the ratio we choose is 70% , 10% , 20% and 10% , 80% , 10% .
C. S UPPLEMENTARY EXPERIMENT RESULTS
Fig.
8 shows the accuracy versus fairness violation for the 3 clients’ cases.
We see a clear advantage of FFL via F ED A VG over the UFL in both 2 clients’ cases and 3 clients’ cases.
The achievable fairness range of FFL via F ED A VG is much wider than that of UFL, though the accuracy of F ED A VG is not guaranteed when the data heterogeneity increases. [Figure] heterogeneity [Figure]
[Table] We also compare F ED A VG , UFL, FFL via F ED A VG [Table] F ED FB, A GNOSTIC F AIR and CFL on logistic regression.
Table 4 shows that our method outperforms UFL and FFL via F ED A VG [Table] while achieving similar performance as A GNOSTIC F AIR and CFL but ensuring higher privacy
[Table]
C. E VALUATION OF DIFFERENTIALLY PRIVATE F ED FB
Since F ED FB exchanges more information than FFL via F ED A VG [Table] we employ differential privacy to decrease information leakage.
We apply the Laplace mechanism to make the information exchanged in each communication round ε -differentially private.
We report the test accuracy and DP disparity of FFL via F ED A VG and F ED FB with different differential privacy levels in Table 5.
Interestingly, we observe that a higher level of differential privacy even helps to improve fairness (see FFL via F ED A VG column), though the accuracy is decreased.
This phenomenon is to be expected since larger noise helps to protect sensitive information, thereby improving fairness and lower accuracy.
Still, Table 5 implies that F ED FB still outperforms FFL via F ED A VG with restrictions on the information exchange.
C. E MPIRICAL RELATIONSHIP BETWEEN ACCURACY , FAIRNESS , AND THE NUMBER OF CLIENTS
We investigate the empirical relationship between accuracy, fairness, and the number of clients.
We generate three synthetic datasets of 3,333, 5,
[Table]
and 6,667 samples, and split them into two, three, and four clients, respectively.
Table 6 shows that our method outperforms under the three cases
[Table]
C. C OMPARISON WITH F AIR F ED
[Table]
As suggested in Ezzeldin et al.
[Table]
we use logistic regression to compare our approach with F AIR F ED . Since F AIR F ED is only applicable to single binary sensitive at- [Table]
[Table]
tribute cases, we report the performance of F AIR F ED on synthetic and Adult datasets in Table 7. We observe that our F ED FB outperforms F AIR F ED in terms of both accuracy and fairness, while F AIR F ED also outperforms FFL via F ED A VG thanks to the additional client reweighting step.
[Table]
To make fairer comparison
[Table]
we follow the exact same setting as Ezzeldin et al.
(2021) to re-split Adult and COMPAS dataset, employ | SPD | = | P (ˆy = 1 | a = 0) − P (ˆy = 1 | a = 1) | as unfairness metric and present the results in Table 8. We observe that F ED FB achieves higher fairness than F AIR F ED while being robust to data heterogeneity. C. C OMPARISON WITH A GNOSTIC F AIR Lastly, we compare our method with A GNOSTIC F AIR (Du et al., 2021), which exchanges the model parameters and the other information after every gradient update to mimic the performance of CFL with F AIRNESS C ONSTRAINT implementation (Zafar et al., 2017c).
Table 9 shows that our F ED FB achieves similar performance as A GNOSTIC F AIR , at much lower cost of privacy.
[Table]