Distributed k-Means and k-Median Clustering on General Topologies

Maria Florina Balcan, Steven Ehrlich, Yingyu Liang

TL;DR

This paper introduces a novel distributed algorithm for $k$-means and $k$-median clustering that operates efficiently across any connected network topology. By decentralizing the construction of a "coreset"—a small, weighted summary of the data—the authors achieve significantly lower communication costs than previous methods while maintaining provable theoretical guarantees on clustering quality.

What Problem Does This Paper Address?

Clustering is a fundamental tool in data science, but traditional algorithms assume all data resides in a single, central location. In the modern era of distributed databases, sensor networks, and massive web-scale datasets, moving all raw data to a central coordinator is often impossible due to bandwidth constraints, privacy concerns, or high latency.

Existing distributed clustering approaches often fall into two camps: those that lack theoretical guarantees on the final clustering quality, and those that use "coresets" but scale poorly. Specifically, previous coreset-based methods (like Zhang et al. [31]) rely on merging local summaries up a communication tree. This "merge-and-reduce" strategy causes errors to accumulate, requiring increasingly larger summaries to maintain accuracy, especially in networks with large diameters (like grids). The authors aim to bridge this gap by providing a method that is both theoretically sound and communication-efficient regardless of the network's shape.

Methods

The researchers leverage the concept of an $\epsilon$-coreset: a small set of weighted points that approximates the clustering cost of the original dataset for any set of centers within a factor of $(1 \pm \epsilon)$.

Their key innovation is a Distributed Coreset Construction (Algorithm 1). Instead of merging local coresets, they distribute the construction process itself:

  1. Local Approximation: Each node independently computes a rough, constant-factor approximation of its local data.
  2. Global Coordination: Nodes share only the total cost of these local approximations across the network. This requires negligible communication.
  3. Importance Sampling: Using the global cost as a baseline, each node samples its own data points with a probability proportional to their contribution to the local clustering cost.
  4. Final Assembly: The global coreset is simply the union of these local samples and the local centers.

To handle communication in arbitrary graphs, they use a Message-Passing approach (Algorithm 3) that propagates information in a breadth-first-search style, ensuring every node eventually receives the necessary data to perform the final clustering.

Figure 1: (a) Each node computes a coreset on the weighted pointset for its own data and its subtrees’ coresets. (b) Local constant approximation solutions are computed, and the costs of these solutions are used to coordinate the construction of a local portion on each node.

Datasets

The authors evaluated their algorithm on a mix of synthetic and real-world benchmarks:

  • Synthetic Data: 20,000 points sampled from Gaussian distributions in $\mathbb{R}^{10}$ ($k=5$).
  • UCI Repository Sets: Spam (4,601 pts), Pendigits (10,992 pts), Letter (20,000 pts), and ColorHistogram (68,040 pts).
  • Large-Scale Data: The YearPredictionMSD dataset, containing 515,345 points in 90 dimensions ($k=50$).

They tested these across various network topologies, including random (Erdős-Rényi), grid, and preferential attachment (Barabási-Albert) graphs.

Key Insights and Ideas

  • Cost-Proportional Sampling is Decentralizable: The most surprising insight is that you don't need a global approximation of the data to perform global importance sampling. Summing local approximation costs provides enough context to coordinate sampling across nodes.
  • Topology Independence: Unlike tree-based merging, the size of the coreset produced by this method does not depend on the network's height or diameter. This makes it far more robust for sparse or "long" networks like sensor grids.
  • Efficiency in Practice: The theoretical bounds for coreset sizes are often pessimistic. Empirically, the algorithm achieves high accuracy (1.1 cost ratio) using only 0.1% to 1% of the points suggested by theory.

Key Results

  • Superior Communication-Accuracy Tradeoff: On spanning trees, the proposed algorithm outperformed the state-of-the-art (Zhang et al.) by approximately 20% in clustering cost for the same communication budget.
  • Robustness to Data Distribution: In scenarios where data is distributed non-uniformly (e.g., nodes have vastly different amounts of data or different local costs), this algorithm consistently outperformed the "COMBINE" baseline (a simple union of local coresets) by 2% to 5% in cost, translating to a 10% to 30% saving in communication.
  • Theoretical Guarantees: The authors provide formal proofs that their algorithm produces a valid $\epsilon$-coreset with high probability, with a total communication cost of $O(mn)$ for general graphs (where $m$ is the number of edges and $n$ is the number of nodes).

Limitations and Future Work

  • Broadcast Overhead: In general graphs, the message-passing approach still relies on broadcasting information, which scales with the number of edges ($m$). While efficient for sparse graphs, very dense networks might still face communication bottlenecks.
  • Metric Space Complexity: While the paper notes the method can be extended to general metric spaces, the primary focus and experimental validation are centered on Euclidean space ($\mathbb{R}^d$).
  • Static Topologies: The current work assumes a connected, static graph. Future research could explore how these algorithms handle dynamic networks where nodes join or leave during the computation.

Summary updated

Abstract

This paper provides new algorithms for distributed clustering for two popular center-based objectives, k-median and k-means. These algorithms have provable guarantees and improve communication complexity over existing approaches. Following a classic approach in clustering by \cite{har2004coresets}, we reduce the problem of finding a clustering with low cost to the problem of finding a coreset of small size. We provide a distributed method for constructing a global coreset which improves over the previous methods by reducing the communication complexity, and which works over general communication topologies. Experimental results on large scale data sets show that this approach outperforms other coreset-based distributed clustering algorithms.
BibTeX
@misc{balcan2013distributed,
  author = {Maria Florina Balcan and Steven Ehrlich and Yingyu Liang},
  title = {{Distributed k-Means and k-Median Clustering on General Topologies}},
  year = {2013},
  eprint = {1306.0604},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1306.0604},
}
Figure