English

Heavy hitters via cluster-preserving clustering

Data Structures and Algorithms 2016-04-06 v1 Machine Learning

Abstract

In turnstile p\ell_p ε\varepsilon-heavy hitters, one maintains a high-dimensional xRnx\in\mathbb{R}^n subject to update(i,Δ)\texttt{update}(i,\Delta) causing xixi+Δx_i\leftarrow x_i + \Delta, where i[n]i\in[n], ΔR\Delta\in\mathbb{R}. Upon receiving a query, the goal is to report a small list L[n]L\subset[n], L=O(1/εp)|L| = O(1/\varepsilon^p), containing every "heavy hitter" i[n]i\in[n] with xiεx1/εpp|x_i| \ge \varepsilon \|x_{\overline{1/\varepsilon^p}}\|_p, where xkx_{\overline{k}} denotes the vector obtained by zeroing out the largest kk entries of xx in magnitude. For any p(0,2]p\in(0,2] the CountSketch solves p\ell_p heavy hitters using O(εplogn)O(\varepsilon^{-p}\log n) words of space with O(logn)O(\log n) update time, O(nlogn)O(n\log n) query time to output LL, and whose output after any query is correct with high probability (whp) 11/poly(n)1 - 1/poly(n). Unfortunately the query time is very slow. To remedy this, the work [CM05] proposed for p=1p=1 in the strict turnstile model, a whp correct algorithm achieving suboptimal space O(ε1log2n)O(\varepsilon^{-1}\log^2 n), worse update time O(log2n)O(\log^2 n), but much better query time O(ε1poly(logn))O(\varepsilon^{-1}poly(\log n)). We show this tradeoff between space and update time versus query time is unnecessary. We provide a new algorithm, ExpanderSketch, which in the most general turnstile model achieves optimal O(εplogn)O(\varepsilon^{-p}\log n) space, O(logn)O(\log n) update time, and fast O(εppoly(logn))O(\varepsilon^{-p}poly(\log n)) query time, and whp correctness. Our main innovation is an efficient reduction from the heavy hitters to a clustering problem in which each heavy hitter is encoded as some form of noisy spectral cluster in a much bigger graph, and the goal is to identify every cluster. Since every heavy hitter must be found, correctness requires that every cluster be found. We then develop a "cluster-preserving clustering" algorithm, partitioning the graph into clusters without destroying any original cluster.

Keywords

Cite

@article{arxiv.1604.01357,
  title  = {Heavy hitters via cluster-preserving clustering},
  author = {Kasper Green Larsen and Jelani Nelson and Huy L. Nguyen and Mikkel Thorup},
  journal= {arXiv preprint arXiv:1604.01357},
  year   = {2016}
}
R2 v1 2026-06-22T13:25:47.544Z