Clustering is a cornerstone of unsupervised learning, but doing it at scale is notoriously difficult. In the "streaming" model, data arrives one point at a time, and memory constraints prevent storing the entire dataset. The challenge intensifies in dynamic streams, where points can be both inserted and deleted—such as when updating a database or tracking active network connections.
For the $k$-median problem (finding $k$ centers that minimize the sum of distances to all points), previous algorithms for dynamic streams suffered from the "curse of dimensionality." To achieve a high-quality $(1+\epsilon)$ approximation, they required memory that grew exponentially with the dimension ($2^d$). This made them impractical for the high-dimensional vectors common in modern machine learning.
This paper introduces the first $(1+\epsilon)$-approximation algorithm for the $k$-median clustering problem in high-dimensional dynamic data streams that uses space polynomial in the dimension ($poly(d)$). By combining hierarchical grid structures with "telescope sum" distance decompositions, the authors provide a way to maintain a small, representative summary of the data—a coreset—even as points are continuously added and deleted.
A Novel Coreset Construction
The core of the paper is a novel coreset construction. A coreset is a small, weighted subset of points that acts as a proxy for the full dataset; any clustering solution evaluated on the coreset yields nearly the same cost as if evaluated on the original data.
To achieve polynomial scaling, the authors employ several key techniques:
- Randomly Shifted Grids: The authors use a hierarchical grid (similar to a quadtree) that is randomly shifted. This ensures that, with high probability, the optimal cluster centers do not fall too close to cell boundaries, allowing the grid to effectively "capture" the data's structure.
- Telescope Sums: They represent the distance from a point to a center as a "telescope sum" of distances between grid cell centers across different levels of the hierarchy. This mathematical trick decomposes the total cost into contributions from each level of the grid.
- Heavy Hitter Tracking: To handle deletions, the algorithm uses $F_2$-heavy hitter sketches and $K$-set data structures. These identify "heavy" grid cells (those containing many points) and sample from them efficiently without storing the points themselves.
- Weight Rectification: Telescope sums naturally produce negative weights, which confuse standard offline clustering solvers. The authors provide a "RectifyWeights" algorithm that pushes these weights down the grid hierarchy to ensure the final coreset only contains non-negative weights.
The biggest insight here is that we don't need to sample from every part of a partition to get a good approximation. By identifying "heavy" cells and using the telescope sum decomposition, the space requirement drops dramatically from $2^d$ to $poly(d)$.
Key Results and Experimental Efficiency
The authors prove a significant theoretical breakthrough: a $(1+\epsilon)$-approximation coreset for $k$-median can be maintained in a dynamic stream using $O(poly(d, k, \log \Delta, 1/\epsilon))$ bits of space. For a stream in a discrete space of size $\Delta^d$, the coreset size is roughly $O(kd^4 \log^4 \Delta / \epsilon^2)$. Furthermore, the algorithm processes each update in $O(dL^2)$ time (where $L = \log \Delta$), making it suitable for high-speed data feeds.
While primarily theoretical, the paper includes a proof-of-concept experiment using a synthetic Gaussian mixture. They generated 65,536 points from a Gaussian mixture model in $\mathbb{R}^2$, rounded to a $512 \times 512$ grid.
In this 2D experiment, the algorithm successfully reduced the 65,536 points down to a coreset of just 90 points. As illustrated in the relative error heatmap above, the algorithm kept the maximum relative error for the clustering cost strictly under 10% (0.1).
Limitations and Future Work
While the complexity is now polynomial rather than exponential, the exponents remain relatively high (e.g., $d^7$ and $L^7$ in the main theorem). In extremely high dimensions, these constants might still pose practical challenges. Additionally, the current proofs assume a discrete Euclidean space. While the authors suggest a modification for continuous space, it adds another layer of complexity to the sampling probabilities.
Ultimately, the authors leave a full, high-dimensional implementation as a future project, meaning real-world performance on massive datasets like high-resolution images or genomic data remains an exciting frontier to explore.
Summary updated