Live data from Hacker News

Perceptual Image Compression at Flickr

code.flickr.net

31–35 of 35 posts

Re: Perceptual Image Compression at Flickr

#31
post #18

I read this looking to see if there was anything we could adapt for mod_pagespeed. Making images smaller without looking worse is, of course, what anyone optimizing images wants. Unfortunately, all they say about how they actually did their perceptual compression is: Ideally we’d have an algorithm which automatically tuned all JPEG parameters to make a file smaller, but which would limit perceptible changes to the im…

There's tools like JpegMini, which tries to detect when artifacts become annoying.

There's an open source re-implementation of their published algorithm on github, but they have patents, which might be part of Flickr's reticence:

https://github.com/dwbuiten/smallfry

Re: Perceptual Image Compression at Flickr

#32
post #29
post #24

Earlier quoted context omitted.

Love the approach. Then they showed their results, and it was only 606 "tests" (showings) of 250 images? On average, just a little more than one same and one different pair-showing for each image. Doesn't strike me as a huge sample.

"Doesn't strike me as a huge sample" Based on what criteria, exactly? 606 comparisons is more than enough to rule out large differences, especially considering that the testers were heavily primed to look for even the tiniest difference and making forced-choices about difference or no difference. Less than 1% difference suggests no real difference.

If it were 606 comparisons of one image I would agree. As it is, it's (on average) just ~2 comparisons of each image

Re: Perceptual Image Compression at Flickr

#33
post #20

Does anyone know what the equivalent imagemagick convert command could be for jpeg and webp? If Firefox supports webp in the near future and IE and Safari support can be done through javascript decompression what could the size reduction with a similar process on webp be compared to jpeg be?

If Firefox supports webp in the near future... Where are you getting this? My understanding is FF still doesn't intend to add WebP support. https://bugzilla.mozilla.org/show_bug.cgi?id=856375

Yes, this was wishful thinking on my part. sp332 is right, there was no decision to implement this. They choose to put their efforts towards mozjpeg instead: http://calendar.perfplanet.com/2014/mozjpeg-3-0/

Re: Perceptual Image Compression at Flickr

#34

I've been using Flickr for a while now, and am a regular visitor to flickr.com/explore. It has always been so painfully slow to load. Moving to the final photo page is even bigger a task. Sometimes, the thumbnails take two minutes to load, but if I get a direct link to the 4MB image, it downloads in literally 5-10 seconds. I'm waiting to get home to see if they've done to fix this mess.

Totally agree. When I'm on Reddit and I spot the link is to flickr.com (rather than say imgur.com) I'll usually skip the link and move to the next post as I know the Flickr photo will take longer than I'm willing to wait.

It's absurd, and it doesn't function! Fix it, Flickr!

Re: Perceptual Image Compression at Flickr

#35
post #32
post #29

Earlier quoted context omitted.

"Doesn't strike me as a huge sample" Based on what criteria, exactly? 606 comparisons is more than enough to rule out large differences, especially considering that the testers were heavily primed to look for even the tiniest difference and making forced-choices about difference or no difference. Less than 1% difference suggests no real difference.

If it were 606 comparisons of one image I would agree. As it is, it's (on average) just ~2 comparisons of each image

That doesn't matter if they're doing paired comparisons, as they are. 2 comparisons of a few hundred images yields far more reliable results than a few hundred comparisons of 2 images, because there are measurements both within and between images.

An analogous situation: if someone runs a blood pressure clinical trial, whose results will you believe more - a trial which measures one person's blood pressure on and off a drug several hundred times over a year or two, or a trial which measures several hundred peoples' blood pressure at the beginning and end of the trial? Obviously the latter, because we know that there are big differences between people which must be measured if we want to make reliable predictions about the effect of the drug in the rest of the population, while additional blood pressure measurements of a person only reduces variability a little bit and helps only a little (because most of the sampling error was removed by the first pair of measurements, and further measurements leave the bulk of variance unaffected).

Post reply on HN