The modern data compression is mainly based on two approaches to entropy coding: Huffman (HC) and arithmetic/range coding (AC). The former is much faster, but approximates probabilities with powers of 2, usually leading to relatively low compression rates. The latter uses nearly exact probabilities - easily approaching theoretical compression rate limit (Shannon entropy), but at cost of much larger computational cost.
Asymmetric numeral systems (ANS) is a new approach to accurate entropy coding, which allows to end this trade-off between speed and rate: the recent implementation [1] provides about $50\%$ faster decoding than HC for 256 size alphabet, with compression rate similar to provided by AC. This advantage is due to being simpler than AC: using single natural number as the state, instead of two to represent a range. Beside simplifying renormalization, it allows to put the entire behavior for given probability distribution into a relatively small table: defining entropy coding automaton. The memory cost of such table for 256 size alphabet is a few kilobytes. There is a large freedom while choosing a specific table - using pseudorandom number generator initialized with cryptographic key for this purpose allows to simultaneously encrypt the data.
This article also introduces and discusses many other variants of this new entropy coding approach, which can provide direct alternatives for standard AC, for large alphabet range coding, or for approximated quasi arithmetic coding.
[1]
David A. Huffman,et al.
A method for the construction of minimum-redundancy codes
,
1952,
Proceedings of the IRE.
[2]
Thomas M. Cover,et al.
Enumerative source encoding
,
1973,
IEEE Trans. Inf. Theory.
[3]
Jorma Rissanen,et al.
Generalized Kraft Inequality and Arithmetic Coding
,
1976,
IBM J. Res. Dev..
[4]
J. Vitter,et al.
Practical Implementations of Arithmetic Coding
,
1991
.
[5]
Wojciech Szpankowski,et al.
Asymptotic average redundancy of Huffman (and other) block codes
,
2000,
IEEE Trans. Inf. Theory.
[6]
Heiko Schwarz,et al.
Context-based adaptive binary arithmetic coding in the H.264/AVC video compression standard
,
2003,
IEEE Trans. Circuits Syst. Video Technol..
[7]
Jarek Duda.
Optimal encoding on discrete lattice with translational invariant constrains using statistical algorithms
,
2007,
ArXiv.
[8]
Jarek Duda,et al.
Asymmetric numeral systems
,
2009,
ArXiv.