arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2302.09239cs.DS
收藏

更快的小波树查询

Faster Wavelet Tree Queries

Matteo Ceregini, Florian Kurpicz, Rossano Venturini

AI总结:

针对非二进制字母表文本的rank和select查询,本文通过将小波树改为四叉树、结合预测模型预取数据减少缓存未命中,使查询速度较SDSL实现提升2至3倍。

摘要:

给定一段文本,rank(排名)和select(选择)查询会返回截至某一位置的字符出现次数(rank),或具有给定排名的字符的位置(select)。这类查询在压缩、计算几何等领域有应用,最突出的是以后向搜索形式应用于模式匹配——后向搜索是众多压缩全文索引的核心支柱。目前在实际应用中,对于非二进制字母表上的文本,小波树可能是最常用的rank和select查询数据结构。\n本文提出了若干技术,与广泛使用的简洁数据结构库(Succinct Data Structure Library, SDSL)中的小波树实现相比,可将查询速度提升2倍(访问和select操作)至3倍(rank操作)。为此,我们将底层树结构从二叉树改为四叉树,并通过使用预测模型近似rank查询以预取实际rank查询所需的全部数据,从而减少缓存未命中。

英文摘要:

Given a text, rank and select queries return the number of occurrences of a character up to a position (rank) or the position of a character with a given rank (select). These queries have applications in, e.g., compression, computational geometry, and most notably pattern matching in the form of the backward search -- the backbone of many compressed full-text indices. Currently, in practice, for text over non-binary alphabets, the wavelet tree is probably the most used data structure for rank and select queries. In this paper, we present techniques to speed up queries by a factor of two (access and select) up to three (rank), compared to the wavelet tree implementation contained in the widely used Succinct Data Structure Library (SDSL). To this end, we change the underlying tree structure from a binary tree to a 4-ary tree and reduce cache misses by approximating rank queries using a predictive model to prefetch all data required for the actual rank query.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑