Skip to content

Comment on Apple Acquires Rapid-Fire Camera App Developer SnappyLabs

Comments

It is amazing that it is still possible to optimize the compression algorithm for JPEG, a file format that is already over 20 years old.

The actual standard allows for a variety of options around how the compression portion is handled -- there is the baseline mode and then options for custom huffman tables, etc. The best source for the JPEG Standard --

http://www.amazon.com/JPEG-Compression-Standard-Multimedia-S...

My memory is a bit fuzzy here, but from what I recall, a friend tried implementing JPEG compression on a parallel system (back in the mid 90s). One of the trouble spots was the reliance on the relationship between blocks regarding prediction of the DC coefficient.

One startup I worked at, we had an entropy encoding method that could add 20-30% additional compression just by recording coefficients. Patent here -- http://www.google.com/patents/US6236762

It sounds like he didn't optimize the algorithm per se; he optimized the implementation of the algorithm for the particular processor. Still very impressive.

"Having developed a blazing fast DCT implementation, Huffman then became a bottleneck. We innovated on that portion with tight hand-tuned assembly code that leverages special features of the ARM processor instruction set to make it as fast as possible.”

I understood he first optimized the algorithm, then tuned it to be even faster on ARM?

I read it as saying that, after optimizing the DCT (lossy) compression as much as he could, he focused on the Huffman (lossless) encoding phase which gave him further optimization opportunities.

I was amazed the first several times I saw things i thought where old as dirt have amazing improvements made. One of the first was about 10 years ago, when a friend made improvements on lighting ballasts in conjunction with solar work. Now I try to keep my eyes open for these opportunities.

I'm not so sure about it, but lossy compression algorithms are usually "non deterministic" and what I mean by that is that there is a target format to encode to, but you have some variation in how you're turning the original data into that

So there's a lot of room in optimising the process

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.