French Fried Files

Back to the Menu Main


Can You Save a File Too Many Times?

 
Since lossy compression discards information every time the file is saved, it stands to reason that there will be a point where too much information will be lost. This is why people say you should always work with an uncompressed original file, but just how badly does repeated saving mangle an image?

To see how repeated loading and saving can affect an image, a simple program was created to repeatedly save an image 2000 times in quick succession. Each iteration worked with the output of the previous call and used a quality setting of 75%. In theory, this should compound the artifacting caused by lossy compression and heavily distort the image.

Surprisingly, the damage done to the butterfly and cat photographs wasn't as obvious as expected. The Cartoon Train image, however, was clearly wrecked.

This suggests that while it's usually a good idea to work from a clean source file, it should be possible to make multiple edits can be made to a photograph before serious problems emerge.


Quality Examples

Butterfly, Saved 2000 times

Base Image

Compressed Image: 19.3 KB
Difference: 42.7%
Most of the artifacts are clustered around the darker parts of the butterfly, as they're bleeding out into the neighboring pixels. This is more obvious around the edge of the wing, as it flows out into the background. That said, judging by the difference map, most of the colors are (computationally) quite off.


Cat, Saved 2000 times

Base Image

Compressed Image: 14.4 KB
Difference: 11.6%
The biggest issue here is the "staircase" like corruption along the windowsill. The pattern of light and dark is broken up by several squares. Further damage is visible just above the cat's ears, though it's not as noticeable.


Train, Saved 2000 times

Base Image

Compressed Image: 12.1 KB
Difference: 31.2%
The train's solid lines and colors really didn't stand up to this test. A lot of the lines have developed chunky pixels that bleed into each other due to the compression algorithm discarding too much information over time.


A WFTID Website