pyaibox.compression package

Submodules

pyaibox.compression.huffman_coding module

class pyaibox.compression.huffman_coding.HuffmanCoding(path)

Bases: object

class HeapNode(char, freq)

Bases: object

compress(outfile=None)
decode_text(encoded_text)
decompress(infile, outfile=None)
get_byte_array(padded_encoded_text)
get_encoded_text(text)
make_codes()
make_codes_helper(root, current_code)
make_frequency_dict(text)
make_heap(frequency)
merge_nodes()
pad_encoded_text(encoded_text)
remove_padding(padded_encoded_text)

Module contents