[gdal-dev] Reading PMTiles With Missing Tiles

Even Rouault even.rouault at spatialys.com
Fri Feb 23 00:37:37 PST 2024


Hi,

this is likely a bug. I would need access to the file to investigate, 
ideally through /vsicurl, /vsis3, etc. . I don't have storage to host 
300 GB. And possibly try to reduce the file size by removing upper zoom 
levels

Even

Le 23/02/2024 à 06:54, Patrick Young via gdal-dev a écrit :
> Hello,
>
> I've been exploring the pmtiles driver a bit, what a great way to read 
> giant blobs of tiles off of cloud storage, really impressed by how 
> fast this is.
>
> I've been encountering a "Non increasing tile_id" when attempting to 
> read from coarser zoom levels for a large (~300GB) pmtile file:
>
> https://github.com/OSGeo/gdal/blob/48ddaf28db2826c635243abd469e7c7d2e749bdc/ogr/ogrsf_frmts/pmtiles/ogrpmtilestileiterator.cpp#L329
>
> For example, this fails for me:
>
> ds = gdal.OpenEx("</vsis3/...", gdal.OF_VECTOR | gdal.OF_READONLY, 
> open_options=["ZOOM_LEVEL=0"])
> lyr = ds.GetLayer()
> for feat in lyr:
>     *** raises RuntimeError: Non increasing tile_id ***
>
> Things seem good when I specify higher zooms (e.g. Z12 or not 
> specified at all), but I can't get features out of the coarser ones.  
> Using the "pmtiles tiles" command, I can access the 0/0/0 tile just 
> fine though.
>
> Any thoughts on what could be wrong?  The file was translated from a 
> mbtiles file via the "pmtiles convert" tool.  ogrinfo is happy with it 
> as well:
>
> INFO: Open of `/vsis3/.../tileset.pmtiles'
>       using driver `PMTiles' successful.
> Metadata:
>   description=mvts for landcover layer
>   format=pbf
>   maxzoom=16
>   minzoom=0
>   name=mvts
>   scheme=tms
>   type=overlay
>   version=2
>   ZOOM_LEVEL=16
> 1: landcover
>
> Thanks,
> Patrick
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/gdal-dev

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



More information about the gdal-dev mailing list