Closed sgillies closed 9 months ago
@anitagraser @Robinlovelace @Nowosad @michaeldorman 👋 I think these changes can simplify your examples. Someone new to geocomputing with Python doesn't need to think about GDAL's virtual filesystems. Rasterio and GeoPandas will allow them to use standard URIs to address datasets.
Thanks for the input and agreed the example with the shorter URL is easier to read. And it aligns with the docs:
The prefixes on which GDAL filesystem handlers are registered are considered by Rasterio to be an implementation detail. You shouldn’t need to think about them when using Rasterio. Use familiar and standard URIs instead, like elsewhere on the internet.
Will let Michael and others comment but it's a :+1: from me.
Thanks @sgillies -- I also like the change.
Thanks @sgillies !
That's great, and good to know it works that way!
Since this book uses Rasterio extensively, it makes sense to align with Rasterio usage and show how to access online resources via standard internet URIs (see https://rasterio.readthedocs.io/en/latest/topics/vsi.html#virtual-filesystems) instead of odd GDAL
/vsicurl/
filenames. 99% of the time, a Python user is better off passing URIs torasterio.open()
and never thinking about GDAL VSI details.