Skip to content

docs: Add an example rendering a multiscale GeoZarr DEM with from_xarray - #1360

Open
kylebarron wants to merge 3 commits into
kyle/raster-xarray-datatreefrom
kyle/raster-xarray-docs
Open

kylebarron wants to merge 3 commits into
kyle/raster-xarray-datatreefrom
kyle/raster-xarray-docs

Conversation

@kylebarron

Copy link
Copy Markdown
Member

Note

This PR was written by Claude (Claude Code), not by @kylebarron.

Last of the stack toward xarray support. Stacked on the DataTree PR.

What I am changing

  • examples/raster-xarray.ipynb: opens carbonplan's public USGS CONUS 10 m DEM pyramid (GeoZarr, Zarr v3, 14 levels) over HTTP as a DataTree, colors elevation with a render_tile callback that makes NaN transparent, and shows it with RasterLayer.from_xarray(tree, render_tile=..., variable="DEM"). A last cell runs the callback on the coarsest level to show the image it produces.
  • The notebook is listed in the docs nav. from_xarray already appears on the RasterLayer API page through mkdocstrings.

How you can test it

  • uv run --frozen jupyter nbconvert --to notebook --execute --stdout examples/raster-xarray.ipynb > /dev/null runs the notebook headless; the map cell produces the widget and the last cell a PNG.
  • uvx juv run examples/raster-xarray.ipynb once a release with from_xarray is on PyPI; until then run it from a checkout.
  • uv run --frozen --group docs mkdocs build --strict and uv run --frozen pytest tests/test_mkdocs_notebook_links.py tests/test_normalize_notebook.py.

🤖 Written by Claude Code

🤖 Generated with Claude Code

@kylebarron
kylebarron added this pull request to stack #1361 November 13, 2026 18:55
@github-actions github-actions Bot added the docs label Nov 13, 2026
@kylebarron
kylebarron force-pushed the kyle/raster-xarray-docs branch from 2c5a93f to 42ba81c Compare November 16, 2026 20:43
kylebarron and others added 3 commits November 16, 2026 16:08
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@kylebarron
kylebarron force-pushed the kyle/raster-xarray-docs branch from 42ba81c to 5619359 Compare November 16, 2026 21:08

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant