NNCP: Lossless Data Compression with Neural Networks
bellard.org
bellard.org
If this sounds far-fetched, consider that he has created FFMPEG, QEMU, LibBF, SoftFP, BPG, TinyEMU, a software implementation of 4G/LTE, a PC emulator in Javascript, the TCC compiler, TinyGL, LZEXE, and a tiny program for computing the biggest known prime number.
And that's just a partial list of his successful projects, which now of course also include software for more efficient lossless compression with deep LSTM and Transformer neural networks.
Any of these projects, on its own, would be considered a notable achievement for an ordinary human being.
Fabrice Bellard deserves some kind of superhuman lifetime achievement award.
Source: https://bellard.org
Indeed. The Tesla of software perhaps.
I just launched JSLinux [1] for fun. You gotta love this dmesg line: [ 0.000000] CPU: vendor_id 'AuthenticX86' unknown, using generic init.
From the conclusion:
“We presented a practical implementation of an LSTM based lossless compressor. Although it is slow, its description is simple and the memory consumption is reasonable compared to compressors giving a similar compression ratio. It would greatly benefit from a dedicated hardware implementation.”
I only skimmed through the paper, but looks to me like this might be a 10X improvement over other LSTM compression methods, not state-of-the-art compression.
That said, I’m far from being an expert in compression and was hoping from someone in HN to explain how relevant this is in their discipline.
I would add that lstm-compress from Byron Knoll, the author of CMIX, already achieved comparable compression ratios at 10x the speed, as is shown in the paper.
No, it's 10x faster than an experimental, completely performance-unoptimized LSTM model that is far from state-of-the-art on its own. From the paper:
"Regarding the speed, our results show that our implementation is much faster than lstm-compress[8] with a similar model and gain. The speed improvement comes from the more optimized matrix multiplication implementation and the larger batch size (16 instead of 1)."
Of most interest here is the library used, LibNC, which might allow us to speed up cmix a bit (even making it 2x faster would already help a lot in testing).
Disclaimer: I've worked on cmix with its author
http://prize.hutter1.net/index.htm
(I've computed that 14,826,395 bytes is required to become the next winner. CMIX comes close, but its huge memory consumption disqualifies it.)
Accelerators are now the norm for this sort of stuff, hence why this is so slow.
Also note this is closed source. Unusual for bellard, and also unusual for this sort of research.
Not wholly unusual for Bellard. E.g., https://bellard.org/lte/
This one makes arithmetic coding "adaptive". Consider this. The rough frequency of `e' in English is about 50%. But if you just seen this partial sentence "I am going to th", the probability/frequency of `e' skyrockets to, say, 98%. In standard arithmetic coding scheme, you would still parametrize you encoder with 50% to encode the next "e" despite it's very likely (~98%) that "e" is the next character (you are using more bits than you need in this case), while with the help of a neural network, the frequency becomes adaptive.
Edit: typo
[1] https://openreview.net/pdf?id=rk8wKk-R-
[1] shows that TCN may outperform LSTM on tasks that really needs memory.
A paper with inductive results is just a first step in a really long process until ideas are commonplace accepted.
He used Transformer, why not TCN?
In this paper, Bellard makes a comparison to the Transformer, some variant of which holds most NLP records. Of note is that in this test, the Transformer did not outperform the LSTM. Is it that Transformers need to be larger to outperform or LSTMs are more suited to compression or that more epochs are required? This deserves further investigation, what are the required conditions for Transformers to underperform LSTMs?