Huffman encoder paralelization with OpenMP. Includes a decoder, but only sequential.
Encoder with OpenMP was part of a university assignment on parallel programming. I decided to also write a decoder for fun. Also, why not?
Usage is simple
./huffman filepath
to encode. This produces filepath.huff file, you can decode it with
./huffman -d filepath
I also provided means to control how many threads are being used, by deafault, the maximum available threads on the CPU will be used.
To change the number of threads, use the -n flag like this:
./huffman -n 4 filepath
This will run the encoder on 4 threads. The flag has no effect on decoder
Just clone the repository and provided you have
- make
- g++ compiler
- openmp library
you can just run
makecommand and the compiled binary should be in /bin directory