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

高效的太字节级文本压缩:基于稳定局部一致性与并行文法处理

Efficient terabyte-scale text compression via stable local consistency and parallel grammar processing

Diego Diaz-Dominguez

AI总结:

提出基于稳定局部一致性的并行文法压缩算法,实现太字节级数据高效处理,在7.9TB细菌基因组上以16线程九小时内完成压缩,体积缩小85倍。

摘要:

我们提出了一种高度可并行化的文本压缩算法,能够高效扩展到太字节级数据集。该方法基于局部一致性文法(一种轻量级压缩形式),并结合简单的再压缩技术以进一步减少空间占用。局部一致性文法算法特别适合扩展,因为它们在压缩文本时仅需极少的辅助信息。我们引入了一个新概念——稳定局部一致性——以实现并行化。若文法算法ALG是稳定的,则对于集合T={T1,T2,...,Tk}中出现的任意模式P,实例ALG(T1),ALG(T2),...,ALG(Tk)会独立地为P生成具有相同拓扑结构的核心。在局部一致性文法中,P的核心是T解析树中节点和边的子集,在P的所有出现中保持不变。这一特性对实现压缩至关重要,但仅在ALG同步字符串解析时成立,例如通过为它们定义共同的非终结符集合。稳定性消除了解析阶段同步的需求。因此,我们可以完全并行地运行ALG(T1),ALG(T2),...,ALG(Tk),然后将所得文法合并为与ALG(T)等价的单一压缩输出。我们实现了上述思想并在大规模数据集上进行了测试。结果表明,我们的方法能够在约九小时内处理多样化的细菌基因组集合(7.9 TB),仅需16个线程和0.43比特/符号的工作内存,生成的压缩表示比原始输入小85倍。

英文摘要:

We present a highly parallelizable text compression algorithm that scales efficiently to terabyte-sized datasets. Our method builds on locally consistent grammars, a lightweight form of compression, combined with simple recompression techniques to achieve further space reductions. Locally consistent grammar algorithms are particularly suitable for scaling, as they need minimal satellite information to compact the text. We introduce a novel concept to enable parallelisation, stable local consistency. A grammar algorithm ALG is stable, if for any pattern $P$ occurring in a collection $\mathcal{T}=\{T_1, T_2, \ldots, T_k\}$, the instances $ALG(T_1), ALG(T_2), \ldots, ALG(T_k)$ independently produce cores for $P$ with the same topology. In a locally consistent grammar, the core of $P$ is a subset of nodes and edges in $\mathcal{T}$'s parse tree that remains the same in all the occurrences of $P$. This feature is important to achieve compression, but it only holds if ALG synchronises the parsing of the strings, for instance, by defining a common set of nonterminal symbols for them. Stability removes the need for synchronisation during the parsing phase. Consequently, we can run $ALG(T_1), ALG(T_2), \ldots, ALG(T_k)$ fully in parallel and then merge the resulting grammars into a single compressed output equivalent to $ALG(\mathcal{T})$. We implemented our ideas and tested them on massive datasets. Our results showed that our method could process a diverse collection of bacterial genomes (7.9 TB) in around nine hours, requiring 16 threads and 0.43 bits/symbol of working memory, producing a compressed representation 85 times smaller than the original input.

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

↑