[gdal-dev] Problem when trying to open files with GDAL from Object Store using vsiswift
I am using GDAL 2.4.1 with Python 3.6 to access rasters in Object Storage using /vsiswift. I need to open around 100 rasters, read their data and capture it in an array. I do not need to have them all available in memory, this is a sequential task , read one
raster, delete dataset and continue with another one within a for loop.
My problem is that, after reading 19 rasters, the 20th one returns a dataset in the Open operation , but returns 'None' when I try the 'ReadAsArray()'. The 20th raster is a valid one, if I move this "failing" raster to the first position in the loop it gets
I did print gdal lastErrorMsg and got the following error: "band 4: IReadBlock failed at X offset 0, Y offset 0: TIFFReadEncodedStrip() failed"
Has anyone else succeded in accessing multiple rasters in the same python program? Is this a known issue? Maybe I have a problem in my code?