English

Count-min sketch with variable number of hash functions: an experimental study

Data Structures and Algorithms 2023-09-08 v2

Abstract

Conservative Count-Min, an improved version of Count-Min sketch [Cormode, Muthukrishnan 2005], is an online-maintained hashing-based data structure summarizing element frequency information without storing elements themselves. Although several works attempted to analyze the error that can be made by Count-Min, the behavior of this data structure remains poorly understood. In [Fusy, Kucherov 2022], we demonstrated that under the uniform distribution of input elements, the error of conservative Count-Min follows two distinct regimes depending on its load factor. In this work, we provide a series of experimental results providing new insights into the behavior of conservative Count-Min. Our contributions can be seen as twofold. On one hand, we provide a detailed experimental analysis of the behavior of Count-Min sketch in different regimes and under several representative probability distributions of input elements. On the other hand, we demonstrate improvements that can be made by assigning a variable number of hash functions to different elements. This includes, in particular, reduced space of the data structure while still supporting a small error.

Keywords

Cite

@article{arxiv.2302.05245,
  title  = {Count-min sketch with variable number of hash functions: an experimental study},
  author = {Éric Fusy and Gregory Kucherov},
  journal= {arXiv preprint arXiv:2302.05245},
  year   = {2023}
}

Comments

short version to appear in SPIRE'23

R2 v1 2026-06-28T08:37:01.716Z