[gdal-dev] Predictor creation option with ZSTD GeoTIFF compression

Koko Alberti kokoalberti at fastmail.com
Thu Aug 2 12:00:47 PDT 2018


Hi,

With ZSTD compression available in GDAL 2.3 I was running some tests to compare it with the other alternatives. According to the docs the PREDICTOR creation option can be used with COMPRESS=ZSTD, but when I run a quick comparison it seems to have no effect on the output file size. Is this correct or is something else going on?

For example, the following commands (GDAL 2.3.1) create output files that all have exactly the same size:

gdal_translate -co COMPRESS=ZSTD -co PREDICTOR=1 test.tif zstd_p1.tif
gdal_translate -co COMPRESS=ZSTD -co PREDICTOR=2 test.tif zstd_p2.tif
gdal_translate -co COMPRESS=ZSTD -co PREDICTOR=3 test.tif zstd_p3.tif

I would expect some differences though, as for other algorithms which support predictor (deflate, lzw) choosing the right value can have quite a big effect on the compression ratio. Tested with files with different data types as well (Byte, Int16, and Float32) with the same effect.

Thanks for any insights.

cheers,
Koko


More information about the gdal-dev mailing list