[Paper Review] Fully Online Grammar Compression in Constant Space
This paper introduces FREQ_FOLCA and LOSSY_FOLCA, novel fully online grammar compression variants that achieve constant working space by retaining only frequent production rules in a hash table, leveraging stream mining techniques. The methods enable efficient compression and decompression of large-scale, noisy repetitive texts—such as human genomes—while maintaining high compression ratios and linear time complexity, outperforming prior methods in memory efficiency and scalability.
We present novel variants of fully online LCA (FOLCA), a fully online grammar compression that builds a straight line program (SLP) and directly encodes it into a succinct representation in an online manner. FOLCA enables a direct encoding of an SLP into a succinct representation that is asymptotically equivalent to an information theoretic lower bound for representing an SLP (Maruyama et al., SPIRE'13). The compression of FOLCA takes linear time proportional to the length of an input text and its working space depends only on the size of the SLP, which enables us to apply FOLCA to large-scale repetitive texts. Recent repetitive texts, however, include some noise. For example, current sequencing technology has significant error rates, which embeds noise into genome sequences. For such noisy repetitive texts, FOLCA working in the SLP size consumes a large amount of memory. We present two variants of FOLCA working in constant space by leveraging the idea behind stream mining techniques. Experiments using 100 human genomes corresponding to about 300GB from the 1000 human genomes project revealed the applicability of our method to large-scale, noisy repetitive texts.
Motivation & Objective
- Address the high memory consumption of existing grammar compression methods when applied to large-scale, noisy repetitive texts such as human genome sequences.
- Overcome the limitation of FOLCA, which requires working space proportional to the SLP size, making it infeasible for noisy, large-scale data.
- Develop fully online grammar compression algorithms that operate in constant working space while preserving high compression efficiency.
- Enable practical compression and decompression of massive repetitive text collections—such as 100 human genomes—on standard hardware.
- Introduce a strategy to retain only frequent production rules in memory, inspired by stream mining, to reduce space usage without sacrificing compression quality.
Proposed method
- Leverage stream mining techniques to maintain only frequently occurring production rules in a hash table, discarding infrequent ones to conserve memory.
- Design FREQ_FOLCA to prioritize and store only the most frequent production rules (based on a frequency threshold k), reducing working space to a constant.
- Design LOSSY_FOLCA to use a lossy filtering strategy that removes infrequent rules based on a parameter ℓ, achieving constant space with controlled loss in compression quality.
- Use a succinct representation of the SLP based on bit strings and label sequences, enabling efficient decompression from secondary storage.
- Integrate a reverse dictionary with a hash table that is kept small by frequency-based filtering, ensuring constant memory usage during compression.
- Perform online compression and decompression by processing the input text in a single pass, maintaining constant space throughout.
Experimental results
Research questions
- RQ1Can grammar compression be made fully online and work in constant space for large-scale, noisy repetitive texts?
- RQ2How can frequent production rules be identified and retained in memory to minimize space usage while preserving high compression ratios?
- RQ3What is the trade-off between compression ratio and working space when using frequency-based filtering of production rules?
- RQ4Can constant-space grammar compression be effectively applied to real-world noisy data such as human genome sequences?
- RQ5How does the performance of the proposed methods compare to existing compressors (e.g., FOLCA, LZMA, BLOCK_FOLCA) in terms of memory, time, and compression ratio?
Key findings
- FREQ_FOLCA and LOSSY_FOLCA achieve constant working space—36–76 GB for FREQ_FOLCA and 36–56 GB for LOSSY_FOLCA—regardless of input size, unlike FOLCA, which required over 100 GB for a 52 GB genome.
- Compression of 100 human genomes (306 GB) completed in under 24 hours using FREQ_FOLCA and LOSSY_FOLCA, while LZMA failed to complete within 5 days.
- LOSSY_FOLCA achieved a compression ratio of 17.45% with 56.9 MB of maximum working space, outperforming BLOCK_FOLCA (25.91% at 34.7 MB) under the same parameter settings.
- FREQ_FOLCA achieved a compression ratio of 19.71% with 76.1 MB of working space, demonstrating a trade-off between compression ratio and memory usage.
- Decompression time for both variants was under 23,000 seconds, showing efficient decompression performance despite constant-space operation.
- The proposed methods successfully handle real-world noisy repetitive data from the 1000 Genomes Project, proving applicability to large-scale genomic data.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.