summaries: The authors of this paper consider the individual fair k-clustering problem, as introduced by Jung et al. [FORC 19]. In this model, for every point $j$ there is a given radius $r_j$, and the goal is to choose a set of centers such that each point has an open center within distance $r_j$ from it, and also one of the standard clustering objective functions is minimized.  Specifically, under the k-median and k-means objectives, the authors provide improved guarantees compared to the state of the art results (Mahabadi and Vakilian [ICML 2020]). For the k-median objective, they give an $(8,8)$-bicriteria algorithm, while the best known result was an $(84,7)$ one. For k-means their result is an $(4,8)$-bicriteria algorithm, while the result of Mahabadi and Vakilian was a $(\gamma,7)$ one, with $\gamma$ being a very large constant. (an $(a,b)$-bicriteria solution has objective cost at most $a$ times the optimal, and for every $j$ it has an open center within distance at most $b \cdot r_j$ from it).  The authors achieve their results via standard LP-rounding techniques. This paper introduces a new algorithm for fair k-clustering problem(specifically when cost is measure with l_p norm for different p values) based on LP rounding. It provides a bi-criteria approximation guarantee for the clustering objective and experiments are provided to validate the theoretical properties. It is also shown how the runtime of the algorithm can be improved using sparsification with minimal effects on the objective. The paper studies the problem of \ell_p norm and center-based clustering with a fairness consistent. The fairness constraint roughly says that no point should be further from its assigned center than it is from its (n/k)-th furthest neighbor. The authors consider a Linear Programming based (approximation) algorithm for this problem.  This submission proposes an approximation algorithm for individual fair k-clustering in a metric space. Here, individual fairness means that each point v has an individual radius $r(v)$ and we require an open facility within radius $r(v)$ of $v$. We may use the radius $r(v)$ to provide each point $v$ with a "fair share" of its assigned facility by, for instance, choosing $r(v)$ as the smallest radius such that $n/k$ points lie within radius $r(v)$ of $v$; as originally proposed by Jung, Kannan, and Lutz.   The approximation algorithm is the main contribution of the submission. It works for any p-norm objective and is bi-criterial, guaranteeing an $2^{1+2/p}$-approximation of the  objective while ensuring an open facility within radius $8r(v)$ of each point $v$. However, it requires a metric space which means, in particular, that all facilities/centers have to be chosen from the point set.  The algorithm roughly works in the following way: First, the authors compute an optimum solution to a linear programming relaxation of the problem. The solution is turned into an input for a filter function by Plesnik/Rita, Moro and Cortez; this function replaces the original point set by a smaller set of representatives. In the original version of the filter, the function may be run until only $k$ representatives remain (a point may represent another if it can serve as the point's facility; hence, in the original filter, the representatives are then chosen as the facilities to open). In this case, however, it may be that the filter stops early as the fairness restriction on the connection radius may make it impossible to cover all points with $k$ representatives. Hence, a final step is required to reduce the set of representatives down to $k$ points. This is done via an LP-rounding algorithm and turns out to be a substantial amount of work. Finally, in order to improve the running time of the algorithm, the authors propose a sparsification technique for the LP-relaxation (whose size is otherwise quadratic in the number of points and could be prohibitive for larger point sets).  An empirical part shows improvements over the previous approach.
abstractText: We study data clustering problems with lp-norm objectives (e.g. k-MEDIAN and k-MEANS) in the context of individual fairness. The dataset consists of n points, and we want to find k centers such that (a) the objective is minimized, while (b) respecting the individual fairness constraint that every point v has a center within a distance at most r(v), where r(v) is v’s distance to its (n/k)th nearest point. Jung, Kannan, and Lutz [FORC 2020] introduced this concept and designed a clustering algorithm with provable (approximate) fairness and objective guarantees for the l∞ or k-CENTER objective. Mahabadi and Vakilian [ICML 2020] revisited this problem to give a local-search algorithm for all lp-norms. Empirically, their algorithms outperform Jung et. al.’s by a large margin in terms of cost (for kMEDIAN and k-MEANS), but they incur a reasonable loss in fairness. In this paper, our main contribution is to use Linear Programming (LP) techniques to obtain better algorithms for this problem, both in theory and in practice. We prove that by modifying known LP rounding techniques, one gets a worst-case guarantee on the objective which is much better than in MV20, and empirically, this objective is extremely close to the optimal. Furthermore, our theoretical fairness guarantees are comparable with MV20 in theory, and empirically, we obtain noticeably fairer solutions. Although solving the LP exactly might be prohibitive, we demonstrate that in practice, a simple sparsification technique drastically improves the run-time of our algorithm.
authors.name: Deeparnab Chakrabarty
authors.name: Maryam Negahbani
references.authors: Mohsen Abbasi Aditya Bhaskara Suresh Venkatasubramanian
references.title: Fair clustering via equitable group representations
references.venue: In Proceedings of the 2021 ACM Conference on Fairness,
references.authors: Sara Ahmadian Ashkan Norouzi-Fard Ola Svensson Justin Ward
references.title: Better guarantees for k-means and euclidean k-median by primal-dual algorithms
references.venue: In Proceedings, IEEE Symposium on Foundations of Computer Science (FOCS),
references.authors: Soroush Alamdari David B. Shmoys
references.title: A bicriteria approximation algorithm for the k-center and k-median problems
references.venue: In WAOA,
references.authors: David Arthur Sergei Vassilvitskii
references.title: K-means++: The advantages of careful seeding
references.venue: In Proceedings, ACM-SIAM Symposium on Discrete Algorithms (SODA),
references.authors: Tanvi Bajpai Deeparnab Chakrabarty Chandra Chekuri Maryam Negahbani
references.title: Revisiting priority k-center: Fairness and outliers
references.venue: In Proceedings, International Colloquium on Automata, Languages and Programming (ICALP),
references.authors: Suman Bera Deeparnab Chakrabarty Nicolas Flores Maryam
references.title: Negahbani. Fair algorithms for clustering
references.venue: In Adv. in Neural Information Processing Systems (NeurIPS),
references.authors: Jarosław Byrka Thomas Pensyl Bartosz Rybicki Aravind Srinivasan Khoa Trinh
references.title: An improved approximation for k-median, and positive correlation in budgeted optimization
references.venue: In Proceedings, ACM-SIAM Symposium on Discrete Algorithms (SODA),
references.authors: Jaroslaw Byrka Krzysztof Sornat Joachim Spoerhase
references.title: Constant-factor approximation for ordered k-median
references.venue: In Proceedings, ACM Symposium on Theory of Computing (STOC),
references.authors: L. Elisa Celis Damian Straszak Nisheeth K. Vishnoi
references.title: Ranking with Fairness Constraints
references.venue: In Proceedings, International Colloquium on Automata, Languages and Programming (ICALP),
references.authors: Deeparnab Chakrabarty Chaitanya Swamy
references.title: Interpolating between k-median and k-center: Approximation algorithms for ordered k-median
references.venue: In Proceedings, International Colloquium on Automata, Languages and Programming (ICALP),
references.authors: Deeparnab Chakrabarty Chaitanya Swamy
references.title: Approximation algorithms for minimum norm and ordered optimization problems
references.venue: In Proceedings, ACM Symposium on Theory of Computing (STOC),
references.authors: Moses Charikar Sudipto Guha Éva Tardos David B Shmoys
references.title: A constant-factor approximation algorithm for the k-median problem
references.venue: Journal of Computer and System Sciences,
references.authors: Xingyu Chen Brandon Fain Liang Lyu Kamesh Munagala
references.title: Proportionally fair clustering
references.venue: In Proceedings, International Conference on Machine Leanring (ICML),
references.authors: Flavio Chierichetti Ravi Kumar Silvio Lattanzi Sergei Vassilvitskii
references.title: Fair clustering through fairlets
references.venue: In Adv. in Neural Information Processing Systems (NeurIPS),
references.authors: Vincent Cohen-Addad C.S. Karthik Euiwoong Lee
references.title: On approximability of clustering problems without candidate centers
references.venue: In Proceedings, ACM-SIAM Symposium on Discrete Algorithms (SODA),
references.authors: Teofilo F. Gonzalez
references.title: Clustering to Minimize the Maximum Intercluster Distance
references.venue: Theoretical Computer Science,
references.authors: Inge Li Gørtz Anthony Wirth
references.title: Asymmetry in k-center variants
references.venue: Theoretical Computer Science,
references.authors: Sudipto Guha Samir Khuller
references.title: Greedy strikes back: Improved facility location algorithms
references.venue: In Proceedings, ACM-SIAM Symposium on Discrete Algorithms (SODA),
references.authors: David G. Harris Shi Li Thomas Pensyl Aravind Srinivasan Khoa Trinh
references.title: Approximation algorithms for stochastic clustering
references.venue: Journal of Machine Learning Research,
references.authors: Dorit S. Hochbaum David B. Shmoys
references.title: A best possible heuristic for the k-center problem
references.venue: Math. Oper. Res.,
references.authors: K. Jain V.V. Vazirani
references.title: Approximation algorithms for metric facility location and kmedian problems using the primal-dual schema and lagrangian relaxation
references.venue: Journal of the ACM,
references.authors: Matthew Joseph Michael Kearns Jamie H Morgenstern Aaron Roth
references.title: Fairness in learning: Classic and contextual bandits
references.venue: In Adv. in Neural Information Processing Systems (NeurIPS),
references.authors: Christopher Jung Sampath Kannan Neil Lutz
references.title: Service in your neighborhood: Fairness in center location
references.venue: In Proceedings, Foundations of Responsible Computing, FORC 2020,
references.authors: Toshihiro Kamishima Shotaro Akaho Hideki Asoh Jun Sakuma
references.title: Fairness-aware classifier with prejudice remover regularizer
references.venue: In Joint European Conference on Machine Learning and Knowledge Discovery in Databases,
references.authors: Tapas Kanungo David M Mount Nathan S Netanyahu Christine D Piatko Ruth Silverman Angela Y Wu
references.title: An efficient k-means clustering algorithm: Analysis and implementation
references.venue: IEEE transactions on pattern analysis and machine intelligence,
references.authors: Ron Kohavi
references.title: Scaling up the accuracy of naive-bayes classifiers: A decision-tree hybrid
references.venue: In ACM SIGKDD International Conference on Knowledge Discovery and Data Mining,
references.authors: Sepideh Mahabadi Ali Vakilian
references.title: individual) fairness for k-clustering
references.venue: In Proceedings, International Conference on Machine Leanring (ICML),
references.authors: Evi Micha Nisarg Shah
references.title: Proportionally fair clustering revisited
references.venue: In 47th International Colloquium on Automata, Languages, and Programming (ICALP 2020),
references.authors: F. Pedregosa G. Varoquaux A. Gramfort V. Michel B. Thirion O. Grisel M. Blondel P. Prettenhofer R. Weiss V. Dubourg J. Vanderplas A. Passos D. Cournapeau M. Brucher M. Perrot E. Duchesnay
references.title: Scikit-learn: Machine learning in Python
references.venue: Journal of Machine Learning Research,
references.authors: Ján Plesník
references.title: A heuristic for the p-center problems in graphs
references.venue: Discrete Applied Mathematics,
references.authors: Clemens Rösner Melanie Schmidt
references.title: Privacy Preserving Clustering with Constraints
references.venue: In Proceedings, International Colloquium on Automata, Languages and Programming (ICALP),
references.authors: Beata Strack Jonathan P DeShazo Chris Gennings Juan L Olmo Sebastian Ventura Krzysztof J Cios John N Clore
references.title: Impact of hba1c measurement on hospital readmission rates: analysis of 70,000 clinical database patient
references.venue: records. BioMed research international,
references.authors: Paulo Rita Sérgio Moro Paulo Cortez
references.title: A data-driven approach to predict the success of bank telemarketing
references.venue: Decision Support Systems,
references.authors: Ke Yang Julia Stoyanovich
references.title: Measuring fairness in ranked outputs
references.venue: In Proceedings, International Colloquium on Automata, Languages and Programming (ICALP), page 22
references.authors: Neal E. Young
references.title: Sequential and parallel algorithms for mixed packing and covering
references.venue: In 42nd Annual Symposium on Foundations of Computer Science,
references.authors: Muhammad Bilal Zafar Isabel Valera Manuel Gomez-Rodriguez Krishna P. Gummadi
references.title: Fairness constraints: Mechanisms for fair classification
references.venue: In Proceedings, International Conference on Artificial Intelligence and Statistics (AISTATS),
references.authors: Rich Zemel Yu Wu Kevin Swersky Toni Pitassi Cynthia Dwork
references.title: Learning fair representations
references.venue: In Proceedings, International Conference on Machine Leanring (ICML),
sections.heading: 1 Introduction
sections.text: As machine learning algorithms are widely used in practice for making high-stakes decisions affecting human lives, there has been a huge body of work on FAIR-ML trying to ensure ‘fairness’ in the solutions returned by these algorithms. There are two large intersecting bodies of work : one body’s main focus in to understand what ‘fairness’ means (e.g. [26, 39, 38, 36, 14, 25]) in various different contexts, and the second body’s focus has been on addressing the algorithmic challenges brought forth by these considerations (e.g., [24, 9, 33, 6, 29, 5]).
  This paper falls in the second class. In particular, we consider an individual fairness model proposed by Jung, Kannan, and Lutz [25] for a k-clustering problem. Given points (clients) X in a space with metric distance d, find k points (facilities) S ⊆ X , minimizing (∑ v∈X d(v, S) p )1/p
  where d(v, S) is v’s distance to the closest point in S. This includes k-CENTER, k-MEDIAN and the popular k-MEANS objective for p =∞, p = 1 and p = 2 respectively, problems which have been extensively studied [12, 23, 27, 4, 2] in the algorithms literature. Jung et. al. [25] proposed that in this context a solution would be deemed individually fair, if for every client v ∈ X there is an open facility not too far from it. More precisely, if there is a facility within distance r(v) which is the smallest radius
  ∗Supported by NSF grant #2041920
  35th Conference on Neural Information Processing Systems (NeurIPS 2021).
  around v that contains n/k points. The rationale behind n/k is that if all the points had equal chance of getting picked as a facility, each client v would expect a facility to be open within distance r(v). Furthermore, this formulation encourages a solution to open more facilities in dense areas of the metric which is motivated by the facility location application of clustering.
  Jung et al. [25] gave a solution where every client v was served within a radius of 2r(v), which as a jargon is called 2-approximate fair solution. However, their solution did not explicitly consider the “objective” function (k-MEANS/k-MEDIAN, for instance) in the clustering problem, which is often used as a proxy to measure the quality of the clustering. This was addressed in a follow up paper by Mahabadi and Vakilian [29] who gave a (7, O(p))-approximation with respect to the ℓp-norm objective. That is, they give a local-search based solution which is 7-approximately fair, but the objective is violated by some Cp-factor where the constant C is rather large (for p = 1, the factor is 84). The theoretical running time of their algorithm is Õ(pk5n4).
sections.heading: 1.1 Our Contributions
sections.text: The main contribution of our paper is to give improved algorithms for this problem using linear programming rounding. Our study stems from two observations: one, that the problem at the core of Jung et al. [25] was in fact studied as “weighted/priority k-CENTER problem” by Plesník[32], and that if all the r(v)’s were the same (which may not at all be the case), then the clustering problem has also been studied under the guise of centridian/ordered median problem [3, 8, 10]. Combining ideas from these two bodies of work, we design an (8, 8) algorithm for the FAIR-k-MEDIAN problem, which obtains an 8-approximation for both cost and fairness (our cost guarantees improve as p grows).
  Result 1. There is an (8, 21+2/p)-approximation algorithm for FAIR-(p, k)-CLUSTERING that runs in LP solving time plus Õ(n2), overall Õ(kn4). In particular, we have (8, 8)-approximation and (8, 4)-approximation algorithms for FAIR-k-MEDIAN and FAIR-k-MEANS, respectively.
  Remark. The approximation factor compares itself with the optimal solution which opens centers at the points in X . This is also the notion considered by [29] and [25]. If the optimal solution is allowed to open centers anywhere in the real space, then one has an additional factor 2 loss in the approximation [15]. Whether this extra hit of factor 2 is necessary, we leave as an interesting algorithmic question.
  Although solving an LP may seem prohibitive in practice, we can obtain a much faster running time by implementing a sparsification routine (inspired by [32, 21]) with a marginal hit in the fairness and clustering cost (see Lemma 5 for details). Empirically, this greatly decreases the running time, and is often faster than the [29] implementation.
  In our experiments, we also find that our theoretical bounds are too pessimistic. Indeed, we show that our algorithm’s cost is at most %1 more than the optimal clustering cost (which does not have any fairness violation), almost always, and never more than %15 in the rest. Furthermore, our maximum fairness violation is at most a factor of 1.27 which is much better than our theoretical guarantee of 8. We also do a more fine-grained analysis of the fairness violation : consider a vector where each coordinate stands for a clients “unfairness” indicating the ratio of its distance to r(v). When we plot this as a histogram, we find that most of the mass is shifted to the “left”, that is, the percentage of clients who satisfy their fairness constraints is significantly larger than in the [29] solution. This seems to suggest the linear program, which is trying to minimize the cost, itself tries to increase the number of fairly treated clients. We leave a theoretical investigation of this phenomenon for future work.
  Our experiments also demonstrate the price of fairness. We find that our linear programs, which maintains absolute fairness, have objective value considerably larger than that of [29]. On the other hand, if we tune the “fairness violation” of the linear program to match that of [29], then the objective value of our algorithm drops. We run experiments to further elaborate on the inherent cost of fairness in our datasets by demonstrating how the optimal cost changes with respect to varying degrees of fairness relaxation.
  It is worth noting that our algorithm works for arbitrary values of r(v) ≥ 0 for points v (and this may be true for [29] as well), and we present our results thus. This setting might be of interest in applications where the “fair radius” may not be n/k but something more nuanced.
sections.heading: 1.2 Other related work
sections.text: k-CENTER has a 2-approximation due to Gonzales, and Hochbaum and Shmoys [17, 21] and they prove it is NP-hard to get better approximations. k-MEDIAN, and k-MEANS are hard to approximate within factors better than 1.73 and 3.94 [19] respectively with current best approximations being 2.67 by [7] and 9 by [2]. Also recently, there has been an improvement on lower-bounds for approximating Continuous k-MEDIAN and k-MEANS where centers can be picked anywhere in the real space. By Cohen-Addad, Karthik, and Lee [15], it is NP-hard to approximate Continuous k-MEDIAN and k-MEANS within factors 2− o(1) and 4− o(1) respectively. FAIR-k-CENTER is a special case of Priority k-CENTER where the radii r(v) in which a point v demands a center at that distance, are general values. [32] introduced this problem and gave a best possible 2-approximation. Gørtz and Wirth [18] study the problem for asymmetric metrics and prove that it is NP-hard to obtain any non-trivial approximation. [5] give a 9-approximation for the problem in presence of outliers and further generalize to constant approximations for general constraints on the solution centers. Another very closely related problem is Chance-k-Coverage introduced in [20] in which for any point v, in addition to r(v), a probability p(v) is given and the goal is to find a distribution on possible solutions such that a solution drawn from this distribution covers v with probability at least p(v). This also has a 9-approximation by [20].
  A clustering problem related to FAIR-k-MEDIAN and FAIR-k-MEANS is the Simultaneous kClustering in which the goal is to find a solution with approximation guarantees with respect to any monotone, symmetric norm. This problem has an O(1)-approximation due to Chakrabarty and Swamy [11] with a line of previous work including [3, 10, 8].
  Another similar notion of individual fairness is introduced by Chen et al. [13] in which a solution is fair if there is no group of size at least n/k for which there exists a facility that would reduce the connection cost of all members of the group if opened. [13] give a (1 + √ 2)-approximation for ℓ1, ℓ2, and ℓ∞ norm distances for the setting where facilities can be places anywhere in the real space. Micha and Shah [30] modified the approach to give close to 2-approximation for ℓ2 and proved the previous results for ℓ1 and ℓ∞ are indeed tight.
  Recently, Abbasi et al. [1] introduced a new notion of fairness centered around providing equitable group representations. In this problem, the points are partitioned into groups and the goal is to minimize the maximum clustering cost a group can have in the solution. The idea is that the cluster centers should represent each group fairly, and this is captured by ensuring that each group’s clustering cost is comparable with the others. This notion is orthogonal to the fairness criteria we study in this paper; Although we could tune the maximum distance the points in a group can have to our solution, that does not give any guarantees with respect to the objective cost and vice versa.
sections.heading: 2 Preliminaries
sections.text: In this section, we formally define our problems, establish some notations, and describe a classic clustering routine due to Hochbaum and Shmoys [21] with modifications by Plesník[32]. Given a subset S ⊆ X , we use d(v, S) to denote v’s distance to the closest point in S. Definition 1 (FAIR-(p, k)-CLUSTERING Problem). The input is a metric space (X, d), radius function r : X → R+, and integers p, k ≥ 1. The goal is to find S ⊆ X of size at most k such that d(v, S) ≤ r(v) for all v ∈ X and the clustering cost (∑ v∈X d(v, S) p )1/p is minimized.
  Let opt be the clustering cost of an optimal solution. For α, β ≥ 1, an (α, β)-approximate solution is S ⊆ X of size at most k with d(v, S) ≤ αr(v) for all v ∈ X and (∑ v∈X d(v, S) p )1/p≤ βopt. In plain English, the fairness approximation is α while the objective/cost approximation is β. Our main result is the following.
  Theorem 1. There is an (8, 21+2/p)-approximation algorithm for FAIR-(p, k)-CLUSTERING that runs in LP solving time plus Õ(n2), overall Õ(kn4).
  The algorithm relies on rounding a solution to the following LP for FAIR-(p, k)-CLUSTERING2 where the optimal LP objective is at most optp. The variable yu denotes the amount by which u ∈ X
  2The LP and its rounding is slightly different for p = ∞; we omit this from this version.
  is open as a center. xvu for v, u ∈ X is the amount by which v is assigned to u. The constraints respectively capture the conditions: every client must connect to someone, k centers are opened, no client can connect to an unopened center, and crucially that a client cannot travel to a center further than r(v).
  optp ≥ min ∑
  v,u∈X d(v, u)pxvu (LP)∑
  u∈X xvu = 1, ∀v ∈ X (LP1)∑
  u∈X yu = k (LP2)
  xvu ≤ yu, ∀v, u ∈ X (LP3)
  xvu = 0, ∀v, u : d(v, u) > r(v) (LP4)
  0 ≤ xvu, yu ≤ 1, ∀v, u ∈ X.
  From here on, we use the notation B(u, r) for u ∈ X and r ∈ R+ to denote the points in a ball of radius r around u. That is B(u, r) := {v ∈ X : d(u, v) ≤ r}. Also, for any set of points U ⊆ X , let y(U) := ∑ u∈U yu. Considering (LP4) and (LP1) the following holds.
  Fact 1. If y is from a feasible LP solution, then y(B(v, r(v))) ≥ 1 for all v ∈ X .
  We now describe a routine Filter due to [32, 21] which is used as a subroutine in our main algorithm. Assume all the points are initially “uncovered”. The routine takes a function R : X → R+, sorts the points in order of increasing R(v)’s. Then it considers the first point in this order, calls it a “representative” and “covers” all the points v at distance at most 2r(v) from it. Call these points D(v). Repeating this procedure until all the points are covered, forms a partition on X such that the representatives are “far apart”, while each non-representative is assigned to a “nearby” representative, among other useful properties listed in Fact 2 and Fact 3.
  Algorithm 1 Filter Input: Metric (X, d), radius function R : X → R+
  1: U ← X ▷ The set of “uncovered points” 2: S ← ∅ ▷ The set of “representatives” 3: while U ̸= ∅ do 4: u← argminv∈U R(v) ▷ The first point in U in non-decreasing R order 5: S ← S ∪ u 6: D(u)← {v ∈ U : d(u, v) ≤ 2R(v)} ▷ D(u) = B(u, 2R(v)) ∩ U and includes u itself 7: U ← U\D(u) 8: end while
  Output: S, {D(u) : u ∈ S}
  Fact 2. [32, 21] The following is true for the output of Filter: (a) ∀u, v ∈ S, d(u, v) > 2max{R(u), R(v)}, (b) The balls {B(u,R(u)) : u ∈ S} are mutually disjoint, (c) The set {D(u) : u ∈ S} partitions X , (d) ∀u ∈ S,∀v ∈ D(u), R(u) ≤ R(v), and (e) ∀u ∈ S,∀v ∈ D(u), d(u, v) ≤ 2R(v).
  Fact 3. For any u ∈ S and w ∈ B(u,R(u)), the unique closest point in S to w is u.
  Proof. Suppose otherwise. That is, there exists v ∈ S not equal to u s.t. d(w, v) ≤ d(w, u). Then d(u, v) ≤ d(u,w) + d(w, v) ≤ 2d(w, u) ≤ 2R(u) which contradicts Fact 2 as we must have d(u, v) > 2max{R(u), R(v)}.
  To elaborate on the importance of Algorithm 1 and build some intuition, we point out the following theorem of [32, 25].
  Theorem 2. Take S the output of Algorithm 1 on a FAIR-(p, k)-CLUSTERING instance with R := r. Then if the instance is feasible, |S| ≤ k and d(v, S) ≤ 2r(v) for all v ∈ X .
  Proof. By Fact 2 we know that {D(u) : u ∈ S} partitions X so for any v ∈ X , there exists a u ∈ S for which v ∈ D(u). Plus, d(v, u) ≤ 2R(v) = 2r(v). Now it only remains to prove |S| ≤ k. To see this, let S∗ be some feasible solution and observe that two different u,w ∈ S, cannot be
  covered by the same center in S∗. Since otherwise, if there exists f ∈ S∗ for which d(u, f) ≤ r(u) and d(w, f) ≤ r(w) by triangle inequality d(u, v) ≤ d(u, f) + d(f, w) ≤ r(u) + r(v) and this contradicts d(u,w) > 2max{r(u), r(v)} from Fact 2.
  But of course, the above theorem does not give any guarantees for the clustering cost (unless p =∞). It might be the case that many points are paying close to 0 towards the clustering cost in the optimal solution, but are made to connect to a point much farther in the above procedure.
  3 Algorithm for FAIR-(p, k)-CLUSTERING problem
  Now we are ready to describe our algorithm Fair-Round which establishes Theorem 1. At a highlevel, we run our Filter routine by defining the input function R in a manner that is conscious of the FAIR-(p, k)-CLUSTERING cost: given (x∗, y∗) which is an optimal solution to (LP), for any v ∈ X let Cv be v’s contribution to the LP cost i.e. Cv := ∑ u∈X d(v, u)
  px∗vu and define R(v) := min{r(v), (2Cv)1/p}. Let us ponder for a bit to see what changes from Theorem 2. For the output S, we still have the fairness guarantee d(v, S) ≤ 2r(v) for all v but since (2Cv)1/p might be less than r(v) for any v, we cannot guarantee that |S| ≤ k. Thankfully, in this case, we can still prove |S| ≤ 2k (Corollary 1). The rest of the algorithm is deciding on a subset of at most k points out of this S to return as the final solution, while ensuring the fairness and cost guarantees are still within constant factor of the optimal. This idea is very similar to existing ideas in [3, 12] which look at the problem without fairness considerations.
  Recall that {D(u) : u ∈ S} partitions X and each u ∈ S is responsible for covering all the points in D(u). Here, we could simply move each point in D(u) to u and divert the y value of each point to its closest point in S. Note that, y(S) = k (Fact 4) and similar to the proof of Theorem 2 we could show yu ≥ 1/2 (Lemma 1) for all u ∈ S hence |S| ≤ 2k (Corollary 1). If this leads to some y-value reaching 1, we open those centers.
  For u ∈ S with yu < 1, if we do not decide to include it in the final solution, we promise to open Su, its closest point in S other than itself. In this case, all the |D(u)| points on u are delegated to Su. Using the fact that yu < 1, we can prove that fairness guarantee (Lemma 3) approximately holds for the points in D(u) even after this delegation.
  To get the clustering cost guarantee, we need to do more work. Observe that, currently, u is already fractionally assigned to v by 1− yu. So if instead of yu ≥ 1/2 we had yu = 1/2 we could ensure that already u is assigned to v by 1/2 thus integrally assigning u to v only doubles the cost. This is why we need to do more work to get yu ∈ {1/2, 1} for u ∈ S (see Lemma 2) and then bound the clustering cost in Lemma 4. Fact 4. y(S) = k and remains so after Line 11.
  Proof. We initialize y to y∗ for which y∗(X) = k by LP2. The algorithm then transfers y(X) to S by Line 11 without changing the total. Afterwards, the modifications in Lines 13 and 19 move the y mass around in S but the total value y(S) remains unchanged.
  Lemma 1. After Line 14 of Algorithm 2, 1/2 ≤ yu ≤ 1 for all u ∈ S.
  Proof. First we argue that yu ≥ 1/2 for all u ∈ S by the end of Line 11. Fix u ∈ S. Per Fact 3 y(B(u,R(u))) is entirely moved to yu. By definition of R(u) there are two cases: Case I, R(u) = r(u) thus yu ≥ 1 as y∗(B(v, r(v))) ≥ 1 for all v ∈ X according to Fact 1. Case II, R(u) = (2Cu)
  1/p then by Markov’s inequality y∗(B(u,R(u))) ≥ 1/2 and after this point, yu is never decreased to below 1/2. More precisely, Cu = ∑ v∈X d(u, v) px∗uv ≥ ∑
  v∈X: d(u,v)>R(u)
  d(u, v)px∗uv ≥ 2Cu ∑
  v∈X: d(u,v)>R(u)
  x∗uv . Considering ∑ v∈X x ∗ uv = 1 by LP1, this implies ∑ v∈X:
  d(u,v)≤R(u) x∗uv ≥ 1/2
  thus y∗(B(u,R(u))) ≥ 1/2. As for proving yu ≤ 1, it might indeed be the case that yu > 1 by the end of Line 11 but the loop ending at Line 14 can guarantee yu ≤ 1 for all u ∈ S. This is because y(S) = k (Fact 4) and we already checked in the beginning of Algorithm 2 that |S| > k.
  Corollary 1. S in Algorithm 2 has size at most 2k.
  Algorithm 2 Fair-Round: FAIR-(p, k)-CLUSTERING bi-criteria approximation Input: Metric (X, d), radius function r : X → R+, and (x∗, y∗) an optimal solution of LP
  1: Cv ← ∑ u∈X d(v, u) px∗vu ∀v ∈ X ▷ v’s cost share in the LP objective 2: R(v)← min{r(v), (2Cv)1/p} ∀v ∈ X 3: S, {D(u) : u ∈ S} ← Filter((X, d), R) 4: if |S| ≤ k then 5: return S 6: end if 7: (x, y)← (x∗, y∗) 8: for all v ∈ X\S do ▷ Direct y mass from outside of S to the closest point in S 9: u← closest point in S to v 10: yu ← yu + yv , yv ← 0 ▷ Note: May cause yu to increase above 1 11: end for 12: while There are u, v ∈ S with yu > 1 and yv < 1 do ▷ Ensure yu ≤ 1 for all u ∈ S 13: yu ← yu − δ, yv ← yv + δ, where δ := min{1− yv, yu − 1} 14: end while ▷ Remark: By now, 1/2 ≤ yu ≤ 1 for all u ∈ S (see Lemma 1). 15: Su ← closest point in S\u to u ∀u ∈ S 16: while There are u, v ∈ S with 17: 1/2 < yu < 1, and yv < 1, 18: d(u, Su)p|D(u)| > d(v, Sv)p|D(v)| do ▷ Move y mass from u to v if u is costlier 19: yu ← yu − δ, yv ← yv + δ, where δ := min{1− yv, yu − 1/2} 20: end while ▷ Remark: At this point, yu ∈ {1/2, 1} for all u ∈ S (see Lemma 2). 21: T ← u ∈ S with yu = 1 22: Consider the forest of arbitrary rooted trees on vertices u ∈ S with edges (u, Su). Let O be
  odd-level vertices in S\T , and E be even-level vertices in S\T . 23: if |E| ≤ |O| then 24: T ← T ∪ E 25: else 26: T ← T ∪O 27: end if Output: T
  Lemma 2. After Line 20 of Algorithm 2, yu ∈ {1/2, 1} for all u ∈ S.
  Proof. Suppose not. Since y(S) = k (Fact 4) and k is an integer, by Lemma 1, there has to be at least two u, v ∈ S with yu, yv ∈ (1/2, 1) which is a contradiction, since either one of them has to be changed to 1/2 or 1 in the while loop ending at Line 20.
  Lemma 3. For all v ∈ X , d(v, T ) ≤ 8r(v).
  Proof. Fix v ∈ X . Since {D(u) : u ∈ S} partitions X there exists u ∈ S such that v ∈ D(u). According to Fact 2 d(v, u) ≤ 2R(v) ≤ 2r(v) by definition of R. If u ends up in T we are done. Else, it has to be that yu < 1 and Su ∈ T . In what follows, we prove that if yu < 1 at Line 20 then d(u, Su) ≤ 6r(v). This implies d(v, Su) ≤ 8r(v) hence the lemma. We know that initially y∗(B(v, r(v))) ≥ 1 per Fact 1 but since v /∈ S, the y mass on B(v, r(v)) has been moved to S by Line 11. If for all w ∈ B(v, r(v)) their closest point in S was u, all of y(B(v, r(v))) would be moved to u then yu = 1 by the end of Line 20. So there must exist w ∈ B(v, r(v)) with x∗vw > 0 along with u′ ∈ S, u′ ̸= u, such that d(w, u′) ≤ d(w, u) which made yw to be moved to u′. By definition of Su, d(u, Su) ≤ d(u, u′). Applying the triangle inequality twice gives:
  d(u, Su) ≤ d(u, u′) ≤ d(u,w) + d(w, u′) ≤ 2d(u,w) ≤ 2(d(u, v) + d(v, w)) ≤ 2(2r(v) + r(v)) = 6r(v)
  where the last inequality comes from Fact 2 stating d(u, v) ≤ 2r(v), and from the fact that x∗vw > 0 implies d(v, w) ≤ r(v) by LP4.
  Lemma 4. (∑ v∈X d(v, T ) p )1/p ≤ ((2p+2)∑v,u∈X Cv)1/p ≤ 21+2/popt.
  Proof. For the proof, we compare ∑
  v∈X d(v, T ) p with the optimal LP cost ∑ v∈X Cv which is
  at most optp. Fix v ∈ X and u ∈ S for which v ∈ D(u). By Fact 2 d(v, u) ≤ 2R(v) ≤ 2(2Cv)
  1/p per definition of R. So moving D(u) to u for all u ∈ S has an additive cost of∑ u∈S ∑ v∈D(u) d(v, u) p ≤ 2p+1 ∑
  v∈X Cv. From now on, assume there are D(u) collocated points on a u ∈ S. Moving around the y mass up to Line 11 adds a multiplicative factor of 2p loss in the approximation ratio. The logic is: if u ∈ S was relying on w ∈ X in the LP solution, meaning, x∗uw > 0 and yw was moved to a u′ ∈ S (due to d(w, u′) ≤ d(w, u)) then the cost u has to pay to connect to u′ is d(u, u′)p ≤ (d(u,w) + d(w, u′))p ≤ 2pd(u,w)p which is a 2p factor worse than the LP cost d(u,w)p it was paying to connect to w earlier.
  At this point (Line 14), note that the cost incurred by u is |D(u)|d(u, Su)p(1 − yu). To elaborate on this, corresponding to y, we define an x such that (x, y) is feasible for LP. Let xuu = yu and xuSu = 1− yu so that LP4 is satisfied for u. Then the cost incurred by u is |D(u)|(d(u, u)pxuu + d(u, Su)
  pxuSu) = |D(u)|d(u, Su)p(1 − yu). The while loop ending at Line 20 does not increase the value of the objective function: As we decrease yu and increase yv, only if the cost incurred by u is bigger than that of v. The last multiplicative factor 2 loss comes from when u ∈ S\T . In which case, yu = 1/2 and Su ∈ T . So by assigning u to Su we pay |D(u)|d(u, Su)p which is twice more than before (as 1 − yu = 1/2). Observe that this last step is why we needed to do all the work to get yu ∈ {1/2, 1} in Lemma 2. Putting the three steps together, the overall cost is at most 2× 2p + 2p+1 = 2p+2 times the LP cost or at most 21+2/popt.
  Proof of Theorem 1. Using Corollary 1 and the fact that |T | ≤ |S|/2 by construction, we have |T | ≤ k. Lemmas 3 and 4 give the fairness and approximation guarantees. As for runtime, notice that Algorithm 2 runs in time Õ(n2). But the runtime is dominated by the LP solving time. According to [37], finding a (1 + ε)-approximation to LP takes time O(kn2/ϵ2). Setting ε = 1/n gives the O(kn4) runtime.
  As evident, the runtime is dominated by the LP solving time. We end this section by descibing the sparsification pre-processing that when applied to the original instance, can tremendously decrease the LP solving time in practice while incurring only a small loss in fairness and clustering cost. One reason why the LP takes a lot of time is because there are many variables; xvu for every v ∈ X and every u within distance r(v) of v. To fix this, we first run the Filter algorithm on the data set with R(v) = δr(v), where δ is a tune-able parameter. It is not too hard to quantify the loss in fairness and cost as a function of δ, and we do so in the lemma below. More importantly, note that when δ = 1, then the number of variables goes down from n to O(k); this is because of the definition of r(v) which guarantees ≈ n/k points in the radius r(v) around v. Therefore, running the pre-processing step would make the number of remaining points ≈ k. In our experiments we set δ to be much smaller, and yet observe a great drop in our running times.
  Algorithm 3 Sparsification + Fair-Round Input: Metric (X, d), radius function r : X → R+, parameter δ > 0
  1: S, {D(u) : u ∈ S} ← Filter((X, d), δr) 2: (x′, y′)← solve LP only on points S with objective function ∑ v,u∈S d(v, u)
  pxvu|D(v)| 3: x∗vw ← x′uw∀v, w ∈ X,u ∈ S : v ∈ D(u) ▷ v’s assignment is identical to its representative u 4: y∗u ← y′u if u ∈ S and 0 otherwise
  Output: Fair-Round((X, d), (1 + δ)r, (x∗, y∗))
  Lemma 5. Algorithm 3 outputs an (8(1 + δ), 21+2/p(1 + (δϕ)p)1/p)-approximation where ϕ = ( ∑
  v∈X r(v) p)1/p/opt.
  Proof. Observe that (x∗, y∗) is not a feasible LP solution anymore. Nevertheless, it will be feasible for when r is dilated by a factor of (1 + δ) in the LP4. Here is how we argue LP4 holds in this case: For any v, w ∈ X for which x∗vw > 0, recall u ∈ S is chosen so v ∈ D(u) and x∗vw := x′uw > 0 meaning d(u,w) ≤ r(u). We have d(v, w) ≤ d(v, u)+d(u,w) ≤ δr(v)+ r(u) ≤ (1+ δ)r(v). The last two inequalities are by Fact 2 as d(v, u) ≤ δr(v) and r(u) ≤ r(v). As for the LP cost of (x∗, y∗),
  it is not longer upper-bounded by optp but rather by optp + ∑ u∈S ∑ v∈D(u) d(v, u) p. This additive
  term is at most ∑
  v∈X(δr(v)) p ≤ (δϕopt)p. Plugging this into Lemma 4 finishes the proof.
sections.heading: 4 Experiments
sections.text: Summary. We run experiments to show that the empirical performance of our algorithms can be much superior to the worst-case guarantees claimed by our theorems (the codes are publicly availably on Github3). While implementing our algorithm, we make the following optimization : instead of choosing the constant “2” in Line 2 (definition of R) in our algorithm, we perform a binary-search to determine a better constant. Specifically, we find the smallest β for which Algorithm 1 gives at most k centers with R(v) := min{r(v), (βCv)1/p} for all v. This step is motivated by the experiments in [25].
  We assess the performance with respect to (a) fairness, (b) objective value, and (c) running times. Due to space restrictions, we focus on the k-MEANS objective and leave k-MEDIAN results to Appendix B. Our fairness violation seldom exceeds 1.3 (compare this to the theoretical bound of 8), and often is much better than that of [29] and [25]. The objective value of our solution is in fact extremely close to the LP solution, which is a lower bound on the optimum cost (compare this to the theoretical bound of 4). This occurs because typically the LP solution itself has many integer entries. Finally, although the “vanilla” running time of the LP is pretty large, our sparsification routine Lemma 5 tremendously reduces the running time.
  Datasets. Similar to [29], we use 3 datasets from the UCI repository4 [16] (also used in previous fair clustsering works of [14, 6]). We use a set of numeric features (matching previous work) to represent data in Euclidean metric. 1- bank [35] with 4,521 points, on data collected by the marketing campaign of a Portuguese banking institution. We use 3 features “age”, “balance”, and “duration”. 2- census [28] with 32,561 points, based on the 1994 US census. Here we use the following 5 features: “age” , “final-weight”, “education-num”, “capital-gain”, and “hours-per-week”. 3- diabetes [34] with 101,766 points, from diabetes patient records from 130 hospitals across US.
  Benchmarks. We compare with the algorithms of [29] and [25]. For [29], we set parameters according to the experimental section of their paper. We remark that in their experimental section they perform 1 swap in their local search instead of the 4-swaps for which they prove their theorem. For our running time comparison, we also compare ours and the above two algorithm’s running times with the popular k-Means++ algorithm of [4] from scikit learn toolkit [31] which has no fairness guarantees.
sections.heading: 4.1 Fairness analysis
sections.text: For any solution T ⊆ X , define the “violation array” θT over v ∈ X as θT (v) = d(v, T )/r(v). This provides a more fine-grained view of the per-client fairness guarantee violation. Similar to [29] we use maximum violation (i.e. maxv∈X θT (v)) as a benchmark for fairness. In Figure 1 we have plotted the maximum violation of our algorithm Fair-Round, [29] (noted as MV), and [25] (noted as JKL). We find that our results are noticeably fairer than [29] while improving over [25] in many cases.
  Next, we compare the histograms of the violation vectors θ as described above. This picture provides a better view of the fairness profile, as just looking at the maximum violation may not be a robust measure; an algorithm that is largely unfair may be preferred to an algorithm that is extremely unfair on a single point but extremely fair on all the rest. We show the histograms of the violation vectors of these algorithms in Figure 2 (for a full set of histograms see Appendix A.1). As an example, even though in bank with k = 20 our maximum violation is slightly worse than [25] our histogram shows that we are slightly fairer overall. We observe that our algorithm ensures complete fairness for at least %80 of the points in almost all the experiments. A theoretical study of the violation vector is interesting and left as future work.
  3https://github.com/moonin12/individually-fair-k-clustering 4https://archive.ics.uci.edu/ml/datasets/
sections.heading: 4.2 Cost analysis
sections.text: In Figure 3 we demonstrate that in our experiments, the objective value almost matches the optimal cost, begin at most %1 more almost always, and never above %15 more than the LP cost. Note that our cost is also higher than that of [29], and the reader may be wondering how the latter can be better than the optimum cost. The reason is that the [29] cost is violating the fairness constraint while the optimal cost is not. To do a more apples-to-apples comparison, one can also allow the same violations as [29] and re-solve the linear program and also our rounding algorithms. On doing so, we do find that our algorithm’s cost becomes lower than that of [29]. Details of this can be found in Appendix A.2. The set-up also allows us to measure the cost of fairness: how much does the linear programming cost and our algorithm’s cost decrease as we relax the fairness constraints. We do this empirical study; see Appendix A.3 for our results.
  Runtime analysis. We run our experiments in Python 3.8.2 on a MacBook Pro with 2.3 GHz 8-Core Intel Corei9 processor and 32 GB of DDR4 memory. We solve our linear programs using the Python API for CPLEX [22]. We demonstrate that even though solving an LP on the entire instance is time consuming, our sparsification step tremendously improves on the runtime (Figure 4) while increasing the clustering cost or fairness performance by a only a negligible margin (see Appendix A.4 for the cost and fairness results). Below, the blue line with circles shows Fair-Round with “vanilla” LP
  solver, and the green line with upside-down triangles Sparse-Fair-Round is the runtimes with the sparse LP solution.
title: Better Algorithms for Individually Fair k-Clustering