func Estimate(b []byte) float64
Estimate returns a normalized compressibility estimate of block b. Values close to zero are likely uncompressible. Values above 0.1 are likely to be compressible. Values above 0.5 are very compressible. Very small lengths will return 0.
func ShannonEntropyBits(b []byte) int
ShannonEntropyBits returns the number of bits minimum required to represent an entropy encoding of the input bytes. https://en.wiktionary.org/wiki/Shannon_entropy
Name | Synopsis |
---|---|
.. | |
dict | |
cmd | |
builddict | |
flate | Package flate implements the DEFLATE compressed data format, described in RFC 1951. |
fse | Package fse provides Finite State Entropy encoding and decoding. |
gzhttp | |
writer | |
gzkp | |
gzstd | |
gzip | Package gzip implements reading and writing of gzip format compressed files, as specified in RFC 1952. |
huff0 | This file contains the specialisation of Decoder.Decompress4X and Decoder.Decompress1X that use an asm implementation of thir main loops. |
ossfuzz | |
cmd | |
s2 | Package s2 implements the S2 compression format. |
cmd | |
s2c | |
s2d | |
snappy | Package snappy implements the Snappy compression format. |
xerial | |
zip | Package zip provides support for reading and writing ZIP archives. |
zlib | Package zlib implements reading and writing of zlib format compressed data, as specified in RFC 1950. |
zstd | Package zstd provides decompression of zstandard files. |