-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Example: Converting GeoTIFF to GeoZarr with Overviews and Metadata #42
Conversation
Just came across earlier related work in this space zarr-developers/zarr-specs#125 and e.g. dynamic chunking at different scales. |
0977740
to
cac9b8a
Compare
added another example to enable _CRS detection in QGIS, following gdal srs-encoding. This can be drag and dropped in qgis (with gdal 3.8+, which can be installed which |
@wietzesuijker this looks very straightforward. Have you seen the discussion at #30? The question here is how you could represent the overview using both regular decimation and zoom-level style tiling. We came up with this PR as a proposal #44. I'd love to hear your thoughts on this. |
Thanks, I just approved your PR and added some feedback. Closing this PR as it has served its purpose. |
@wietzesuijker I am using the example file you provided here as a test case for #46 and I saw, that the X and Y dimensions in the zarr file is shifted by 5. In the Geotiff the X dims goes from 400000 to 481910 and the Geozarr X dimension goes from 40005 to 481915. |
@felixcremer cool, glad to see it's of some use! The "shift" is because rioxarray uses pixel centroids for the xarray grid, which I expect / find desirable. |
Is this shift in the meaning of the dimension noted somewhere in the metadata of the zarr file? |
You could make a case to make this more explicit, but imo it's just a feature of how xarray interprets georeferenced arrays. Some further details here. |
I still have some questions while working through this: |
Added a script that demonstrates converting a GeoTIFF file to "GeoZarr" format, incorporating pyramid overviews and relevant metadata to align with the GeoZarr specification. The script includes:
Purpose: Get a mutual understanding on the format of GeoZarr for geospatial datasets.
Feedback Welcome: Suggestions for improvements or any corrections are appreciated to ensure this example is helpful and accurate.
Not necessarily proposing we add this to the spec repo, just a way to share this for PR reviews.