Top-rated recipes tagged "data_compression"http://code.activestate.com/recipes/tags/data_compression/top/2011-01-28T04:18:30-08:00ActiveState Code RecipesFibonacci Data Compression (Python)
2011-01-28T04:18:30-08:00FB36http://code.activestate.com/recipes/users/4172570/http://code.activestate.com/recipes/577554-fibonacci-data-compression/
<p style="color: grey">
Python
recipe 577554
by <a href="/recipes/users/4172570/">FB36</a>
(<a href="/recipes/tags/algorithm/">algorithm</a>, <a href="/recipes/tags/algorithms/">algorithms</a>, <a href="/recipes/tags/data_compression/">data_compression</a>).
</p>
<p>Data compression via Fibonacci encoding.</p>
Shannon-Fano Data Compression (Python)
2010-12-18T22:09:40-08:00FB36http://code.activestate.com/recipes/users/4172570/http://code.activestate.com/recipes/577502-shannon-fano-data-compression/
<p style="color: grey">
Python
recipe 577502
by <a href="/recipes/users/4172570/">FB36</a>
(<a href="/recipes/tags/algorithm/">algorithm</a>, <a href="/recipes/tags/algorithms/">algorithms</a>, <a href="/recipes/tags/data_compression/">data_compression</a>).
Revision 3.
</p>
<p>Shannon-Fano Data Compression.
It can compress any kind of file up to 4 GB.</p>
<p>(But trying to compress an already compressed file like zip, jpg etc. can produce a (slightly) larger file though. Shannon-Fano is not the best data compression algorithm anyway.)</p>
Huffman Data Compression (C++)
2010-12-01T02:47:09-08:00FB36http://code.activestate.com/recipes/users/4172570/http://code.activestate.com/recipes/577480-huffman-data-compression/
<p style="color: grey">
C++
recipe 577480
by <a href="/recipes/users/4172570/">FB36</a>
(<a href="/recipes/tags/algorithm/">algorithm</a>, <a href="/recipes/tags/algorithms/">algorithms</a>, <a href="/recipes/tags/datastructures/">datastructures</a>, <a href="/recipes/tags/data_compression/">data_compression</a>).
Revision 2.
</p>
<p>Huffman encoding (data compression).
Usage: huffman -i [input file name] -o [output file name] [-e|d]</p>
File Uniter (C++)
2010-12-01T03:10:13-08:00FB36http://code.activestate.com/recipes/users/4172570/http://code.activestate.com/recipes/577481-file-uniter/
<p style="color: grey">
C++
recipe 577481
by <a href="/recipes/users/4172570/">FB36</a>
(<a href="/recipes/tags/data_compression/">data_compression</a>).
</p>
<p>Unites N files into a single file (or separates them back).</p>
<p>This utility can be used together w/ my other post titled "Huffman Data Compression" to enable compression of multiple files.</p>