Home Creators Posts Import Register Favorites Logout

Downloads

Content

This is an expansion of my popular Medium article comparing the main EXR image compression formats. Included are new test images and updated methodology, new charts, and raw data for reference.

As an artist I often wondered what exactly the difference is between the many EXR formats. Is PIZ better than ZIP? What about RLE? Is DWAA too compressed to be usable? I set out to do a thorough, scientific comparison to answer those questions!

Test Setup

To start I created two test images. The first is a 11472x7296 color image created from a combination of four high-res RAW photos found here.

The second is the 4096x4096 normal map from Eisko's Louise asset, desaturated, darkened and contrast increased for clarity. You can download the entire asset here.

I created an uncompressed EXR version of both images to use as the base for the file write tests.

I tested write performance using oiiotool (OpenImageIO-Arnold 2.4.1.1dev). Read performance was measured with the Exr-IO (2.06) plugin for Photoshop (24.4.0). For the animation test I brought the images into Nuke Non-Commercial (14.0v2) and piped them into a 24 frame transform node that rotated the image 360 degrees and zoomed it 2x. The computer I used is an AMD Ryzen 9 4900HS 3.00 GHz laptop with 16GB RAM and Windows 10.

All the raw data is attached at the end of article in .txt format.

With the technical details out of the way, let's dive in!

Results

First up, file size. I used ZIP as the baseline (colored blue) since it is arguably the most common/popular format. Any algorithm that outperforms ZIP is colored green, any that match it are orange, and any that underperform are red. The charts show percent of baseline.

Next, here is the write performance of each algorithm:

Next, read performance:

Finally, let's look an animation performance in Nuke:

The general takeaways from this data are that there are significant differences in file size and write performance between the different formats. Read performance is quite similar. Animation times are generally comparable, with a few slower outliers such as ZIPS and RLE.

Outside of raw numbers, one major concern is how the lossy formats (DWAA/B, B44/A) compare with the lossless ones in terms of data integrity. This could especially be an issue when it comes to storing highly detailed displacement maps for 3D rendering. You want to avoid compression artifacts in that scenario at all costs.

The good news is that the lossy formats are essentially visually lossless. You have to get in really close to see the difference between uncompressed, DWAA 45 and DWAA 100, for example. Yes, there are slight changes, but in practice you're never going to see them. The algorithms are very impressive in this regard. You get huge file size savings at basically no cost.

But while these formats are visually lossless, they are mathematically lossy. Below are B44 and DWAA45 overlaid on the baseline grayscale image with a difference blending mode. Exposure was increased 10x for visual clarity. Keep in mind that without the exposure increase the difference is invisible. This is only to demonstrate the extent of changed pixel values in the compressed images versus the original.

Compression causes mathematical differences in the images, but it's debatable if this matters in the real world. If you want maximum fidelity for displacement maps then you would choose one of the lossless EXR formats. However, it is certainly worth testing DWAA in specific projects to see if the differences are actually visible.

Conclusions

All in all, ZIP is a good general purpose choice. Decent file size, lossless, fine read and write times and animation performance. The other lossless formats may offer benefits in one area or another and may perform better in certain situations. For example, PIZ is recommended in the OpenEXR docs for images with film grain.

On the lossy side, DWAA is king. Interestingly, there seems to be little reason to prefer lossless EXRs in most, if not all, cases. It may be worth standardizing around a lossless format such as ZIP for ultimate peace of mind, but in practice DWAA will likely perform perfectly in the vast majority of situations.

Files

Comments

No comments found for this post.