Hum, it would be useful if you could subset the input file to the minimum needed to reproduce the error and (possibly privately) share it to me.

Even

Le 20/08/2025 à 23:36, Javier Jimenez Shaw a écrit :
Right. it fails

$ gdal_translate web_mercator.tif web_mercator_jpeg.tif -co COMPRESS=JPEG -co BIGTIFF=YES -of GTIFF -co TILED=YES -co BLOCKXSIZE=512 -co BLOCKYSIZE=512 -oo NUM_THREADS=ALL_CPUS
Input file size is 677881, 303664
0..                              - estimated remaining time: 00:31:20ERROR 1: LZWDecode:Not enough data at scanline 0 (short 2 bytes)

But if I change -oo with -co, it fails somewhere else:

$ gdal_translate web_mercator.tif web_mercator_jpeg_co.tif -co COMPRESS=JPEG -co BIGTIFF=YES -of GTIFF -co TILED=YES -co BLOCKXSIZE=512 -co BLOCKYSIZE=512 -co NUM_THREADS=ALL_CPUS
Input file size is 677881, 303664
0...10...                                            - estimated remaining time: 00:10:55ERROR 1: web_mercator.tif:Using code not yet in table
ERROR 1: TIFFReadEncodedTile() failed.
ERROR 1: web_mercator.tif, band 1: IReadBlock failed at X offset 2570, Y offset 216: TIFFReadEncodedTile() failed.


On Wed, 20 Aug 2025 at 22:43, Even Rouault <even.roua...@spatialys.com> wrote:



    Can I do other useful tests tonight?

    Maybe just check/confirm that the issue is multithreading on the
    decoding side (which it looks to be) with:

    gdal_translate web_mercator.tif web_mercator_jpeg.tif -co
    COMPRESS=JPEG -co BIGTIFF=YES -of GTIFF -co TILED=YES -co
    BLOCKXSIZE=512 -co BLOCKYSIZE=512 -oo NUM_THREADS=ALL_CPUS

    where web_mercator.tif is LZW or Deflate compressed


-- http://www.spatialys.com
    My software is free, but my time generally not.

--
http://www.spatialys.com
My software is free, but my time generally not.
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to