Using the GridR’s chain grid resampling API
This guide walks you through GridR’s chain grid resampling API,
basic_grid_resampling_chain, in a series of focused tutorials. The
chain layer is the file-oriented wrapper around the core
array_grid_resampling function: it reads from and writes to rasterio
datasets, and processes the output in memory-efficient strips and tiles.
Each page is self-contained and executable as a Jupyter notebook — you can follow them in order or jump directly to the topic you need. Pages declare their prerequisites and end with a pointer to the next logical step.
Recommended reading order
The pages are ordered for first-time readers below. Use the Previous /
Next links at the bottom of each page to navigate sequentially. If you
are already familiar with the core API (array_grid_resampling),
start with the overview to see how chain arguments map to their core
counterparts.
Overview — relationship between the chain and core layers
Getting started — your first call to
basic_grid_resampling_chainOutput mask — requesting an output validity mask
Grid mask — flagging grid nodes as invalid
Source mask — flagging source raster pixels as invalid
Geometry masks — using Shapely polygons as masks
Shift and window —
grid_shiftand computation windowI/O and memory — strips, tiles, logging