Introduction
This paper introduces a near-linear time algorithm for fair $k$-median clustering, overcoming the massive computational bottleneck of previous methods. By embedding data into tree structures (HSTs) and using a greedy top-down decomposition, the authors scale fair clustering from a few thousand points to datasets with over two million points while maintaining high-quality results.
The Problem: Monocultures in Clustering
Standard clustering algorithms (like $k$-means or $k$-median) group data points based solely on proximity. However, in sensitive applications like hiring or lending, these clusters might inadvertently become "monocultures"—for example, a cluster representing "high-potential candidates" might end up being 99% male.
To fix this, researchers introduced Fair Clustering, where each cluster must maintain a "balanced" representation of different groups (e.g., a specific ratio of red points to blue points). The state-of-the-art approach involved a two-step process:
- Fairlet Decomposition: Group points into tiny, fair "atoms" called fairlets.
- Standard Clustering: Run a traditional clustering algorithm on these fairlets.
The catch? The original algorithm for Step 1 was super-quadratic ($O(n^2)$ or worse). If you had 100,000 points, the algorithm would crawl to a halt. This paper addresses the scalability gap, making fair clustering practical for modern, massive datasets.
Methodology: Near-Linear Time Decomposition
The authors propose a scalable fairlet decomposition algorithm that runs in nearly linear time ($O(n \log n)$). Their approach relies on three main technical pillars:
- Tree Embedding (HST): They first map the high-dimensional Euclidean data points into a Hierarchical Well-Separated Tree (HST). This is a standard technique that approximates distances between points using the structure of a tree, simplifying complex spatial relationships into parent-child relationships.
- Minimum Heavy Points Problem: On this tree, they define a new optimization problem. They want to partition points into fairlets while minimizing "heavy points"—points that cannot be balanced at a lower level of the tree and must be "passed up" to a higher level (increasing the clustering cost).
- Top-Down Greedy Decomposition: The algorithm traverses the tree from the root down to the leaves. At each node, it greedily matches points into fairlets. If a node has a surplus of one "color," those points are marked as "heavy" and handled at the next level.
By using a tree structure, the algorithm can satisfy fairness constraints locally (within small subtrees) which naturally aggregates into global fairness. While tree embeddings usually introduce a logarithmic distortion ($\log n$) in theory, the authors found that for fair clustering, this trade-off is incredibly beneficial. The speedup gained far outweighs the slight theoretical loss in distance accuracy. Furthermore, unlike simple downsampling, this method uses the entire dataset, leading to more robust clusters because no data is ignored.
Key Results
The authors evaluated their algorithm on four real-world datasets from the UCI Machine Learning Repository: Diabetes, Bank, Census, and Census II.
Massive Speedup
The algorithm scales almost linearly. On the Census II dataset (2.4 million points, 25 dimensions), the fairlet decomposition took only about 349 seconds. Previous quadratic algorithms would have taken days or weeks to process the same data.
Better Quality
Surprisingly, the new algorithm often produced lower clustering costs than the original 2017 quadratic algorithm on smaller benchmarks. For instance, on the Diabetes dataset, the fairlet decomposition cost and the final fair clustering cost were both significantly reduced compared to the baseline.
While the theoretical approximation factor includes a $\log n$ term, the experimental results show that the algorithm performs much better in practice than the "worst-case" theory suggests.
Limitations and Future Work
- Approximation Factor: The theoretical guarantee for the approximation factor is somewhat high ($O(d \cdot (r^8 + b^8) \cdot \log n)$). While it performs great in practice, closing the gap between this theoretical bound and a constant-factor approximation in linear time remains an open challenge.
- Euclidean Focus: The current implementation is optimized for Euclidean spaces. Extending this to more general metric spaces or non-numerical data could be a future direction.
- Weighted Points: The current model assumes all points have equal weight. Integrating this with "core-sets" (which use weighted points to summarize data) would require further algorithmic adjustments.
Summary updated