[gdal-dev] Help requested: Concurrent read of a GeoTiff
Grégory Bataille
gregory.bataille at gmail.com
Thu Mar 16 09:16:20 PDT 2017
Hello all,
Reaching out to the community caused I have failed for the past few days.
*short version*, I'm trying to multithread the gdal2tiles utility, and I'm
getting this
Generating Base Tiles:
ERROR 1: LZWDecode:Wrong length of decoded string: data probably corrupted
at scanline 256
ERROR 1: TIFFReadEncodedTile() failed.
ERROR 1:
/Users/gbataille/Downloads/Project_58704_transparent_mosaic_group1.tif,
band 1: IReadBlock failed at X offset 1, Y offset 0
ERROR 1: GetBlockRef failed at X block offset 1, Y block offset 0
ERROR 1: gba.vrt, band 1: IReadBlock failed at X offset 0, Y offset 0
Any idea?
*Long version*
So I'm trying to add multithreading to gdal2tiles. I know it's possible,
others like
https://gitlab.com/GitLabRGI/geopackage-python/blob/master/Packaging/tiles2gpkg_parallel.py
have done it.
I wanted a slightly different approach where I compute all the tile
coordinates to generate, then I create the tiles one by one in multiple
processes
- I can't see anything that I'm doing very differently from the above
project
- I have confirmed that if I run my code with a pool of one process (still
a sub process, but a single one) then it works as expected
- It fails only when I use more than 1 sub-process, i.e. I guess it's some
concurrent file access that fails.
The trouble is that others have done it, so there is a way :)
Have you seen this error? Does it ring any bells that could point me in the
right direction?
Thanks
---
Gregory Bataille
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20170316/c144f11e/attachment-0001.html>
More information about the gdal-dev
mailing list