Stories
Slash Boxes
Comments

SoylentNews is people

posted by Fnord666 on Sunday March 19 2017, @10:09PM   Printer-friendly
from the just-use-a-photocopier-multiple-times dept.

Google has developed and open-sourced a new JPEG algorithm that reduces file size by about 35 percent—or alternatively, image quality can be significantly improved while keeping file size constant. Importantly, and unlike some of its other efforts in image compression (WebP, WebM), Google's new JPEGs are completely compatible with existing browsers, devices, photo editing apps, and the JPEG standard.

The new JPEG encoder is called Guetzli, which is Swiss German for cookie (the project was led by Google Research's Zurich office). Don't pay too much attention to the name: after extensive analysis, I can't find anything in the Github repository related to cookies or indeed any other baked good.

There are numerous ways of tweaking JPEG image quality and file size, but Guetzli focuses on the quantization stage of compression. Put simply, quantization is a process that tries to reduce a large amount of disordered data, which is hard to compress, into ordered data, which is very easy to compress. In JPEG encoding, this process usually reduces gentle colour gradients to single blocks of colour and often obliterates small details entirely.

The difficult bit is finding a balance between removing detail, and keeping file size down. Every lossy encoder (libjpeg, x264, lame) does it differently.


Original Submission

 
This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
  • (Score: 0) by Anonymous Coward on Monday March 20 2017, @04:49AM

    by Anonymous Coward on Monday March 20 2017, @04:49AM (#481361)

    Easy: filesize. Disk is cheap and getting cheaper all the time, but it's neither free nor infinite, and PNG compression gets awful rates with photos with the quality difference not mattering to most people.
    JPEGs are fairly small, and that matters a bunch to more than 90% of people taking pictures with their camera (so they don't have to delete pictures off the card nearly as frequently). It's not the most relevant thing in the age of cheap 64GB microSD storage, but it still matters.
    If the quality loss matters (read: invest in a camera that isn't cheaply made consumer-grade crap), many cameras do offer to save in a raw or uncompressed format.

    Lazy, single datapoint: resaving a 5.36MB PNG image made it go down to 2.8MB as a JPG file at "100" quality.
    On a camera, that's literally double the pictures you can save, and most people don't care or notice the quality drop.
    On the web, that's literally half the bandwidth cost (and time spent downloading -- it'll be quick on modern connections, but downloading several 5MB images will take a noticeable amount of time for most people still), and generally you'd end up dropping the quality lower to 85 (875k for this image) or 70 (640k for this image) on the web anyway (or even lower, although fairly artifacted at this point, at quality 30, it's still fairly clear, and now only 360kB).

    in addition, JPEG hasn't actually been beaten in quality to filesize enough to matter by other lossy formats (admittedly, mostly because of work like this due to JPEG being super-common and widely supported rather than it being some kind of superior lossy image format; "enough to matter" is a consideration simply because JPEG is the only widely supported lossy image format and you'd need a fairly big improvement to get people to switch)