A package for canonical Huffman compression
Project description
Canonical Huffman-Compression
I created this code because I wanted an implementation of the Huffman algorithm that I couldn't find in python. It uses canonical code and saves the Huffman code dictionary with a combination of sorted symbols and the number occurrences for each code length. This is ideal for situations where the number of symbols used is significantly smaller than the number of possible symbols.
In addition to the Huffman compression/decompression, it allows for the saving and loading of compressed files. The data input must be formatted as a list of integers.
TO USE: Start off with huffman_demo.py. I believe the implementation is fairly straightforward
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for canonical_huffman_compression-0.1.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 401ebb5abfa534d62d0447580d4808a41e88c362d573625e1665742caadb1c16 |
|
MD5 | 069530004f5f3ef6a10c646b98ad6057 |
|
BLAKE2b-256 | 221edf1b60ecdbb588a588fcb8379e50192f0ad988848308a99eea94e0f255a9 |
Hashes for canonical_huffman_compression-0.1.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 888f4a5fbc4ad72f7d55cfd2c20c8db88c73184e9f651a010ec410cd81643404 |
|
MD5 | bea29da9ce935e61a896be15bafc68a8 |
|
BLAKE2b-256 | 0f2f10c228c6c936a6b4ebe97aec5bff760776c8b9f2559b44223eb22f31f12a |