Resample or reproject a grid
You are viewing in-progress documentation for v2. Switch to the stable version for the current production release.
POST /domains/{domain_id}/grids/resample re-grids a source grid onto a
target lattice or resolution. Grids from different sources land on different
lattices — LANDFIRE fuels at 30 m, 3DEP topography at 1 to 30 m, an uploaded
raster at its own resolution. To combine or export them together, they must
share one grid.
Two ways to specify the target:
- Align to another grid — match an existing grid’s cell size and origin. Use this before a combined export.
- Resample to a resolution — re-grid to a cell size, anchored to the domain.
Prerequisites
Section titled “Prerequisites”-
An API key: my-api-key.
-
A domain: your-domain-id.
-
A completed source grid to resample — e.g. the fuel-load grid from Build a surface fuel grid from LANDFIRE. Record its id: grid-to-resample.
Recipe A — align to another grid’s lattice
Section titled “Recipe A — align to another grid’s lattice”To match another grid’s lattice, set alignment.target to "grid" and
grid_id to that grid. The result adopts that grid’s cell size and origin, so
the two line up cell-for-cell.
curl -X 'POST' \ 'https://api.fastfuels.silvxlabs.com/v2/domains/your-domain-id/grids/resample' \ -H 'accept: application/json' \ -H 'api-key: my-api-key' \ -H 'Content-Type: application/json' \ -d '{ "name": "Surface fuel loads aligned to topography grid", "source_grid_id": "grid-to-resample", "alignment": { "target": "grid", "grid_id": "grid-to-align-to" }}'import fastfuels_sdk.v2 as ff
ff.set_api_key("my-api-key")
source_grid = ff.get_grid("your-domain-id", "grid-to-resample")target_grid = ff.get_grid("your-domain-id", "grid-to-align-to")
grid = source_grid.resample( align_to=target_grid, name="Surface fuel loads aligned to topography grid",){ "id": "your-grid-id", "domain_id": "your-domain-id", "name": "Surface fuel loads aligned to topography grid", "description": "", "status": "pending", "progress": null, "created_on": "2026-11-05T18:48:02.650716", "modified_on": "2026-11-05T18:48:02.650716", "checksum": "b66f28e77dc64056b4c28223a8f55a02", "source": { "name": "resample", "source_grid_id": "grid-to-resample", "source_grid_checksum": "dc891eb97b55438cb736bc90b73e74bd", "alignment": { "target": "grid", "grid_id": "grid-to-align-to", "resolution": null, "method": null }, "method_overrides": {} }, "modifications": [], "bands": [ { "key": "fuel_load.1hr", "name": "1-hour Fuel Load", "description": "Oven-dry mass per unit area of 1-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 0, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 1.3001821041107178, "mean": 0.3080750756200265, "std": 0.4163060013339203 } }, { "key": "fuel_load.10hr", "name": "10-hour Fuel Load", "description": "Oven-dry mass per unit area of 10-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 1, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.5380064249038696, "mean": 0.2154931436865418, "std": 0.149978944842402 } }, { "key": "fuel_load.100hr", "name": "100-hour Fuel Load", "description": "Oven-dry mass per unit area of 100-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 2, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.3362540006637573, "mean": 0.11744812236891852, "std": 0.1332688541789988 } }, { "key": "fuel_load.dead_herb", "name": "Dead Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of cured herbaceous fuels. Takes the dead 1-hour fuel moisture.", "type": "continuous", "unit": "kg/m**2", "index": 3, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.150193452835083, "mean": 0.04667122676140732, "std": 0.04506438979507076 } }, { "key": "fuel_load.live_herb", "name": "Live Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of live herbaceous fuels: the uncured part of the herbaceous load.", "type": "continuous", "unit": "kg/m**2", "index": 4, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.07397587597370148, "mean": 0.02298731718212366, "std": 0.022195890140762828 } }, { "key": "fuel_load.live_woody", "name": "Live Woody Fuel Load", "description": "Oven-dry mass per unit area of live woody fuels.", "type": "continuous", "unit": "kg/m**2", "index": 5, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.8630518913269043, "mean": 0.13079034814680063, "std": 0.11863219901758143 } }, { "key": "fuel_depth", "name": "Fuel Bed Depth", "description": "Vertical depth of the surface fuel bed.", "type": "continuous", "unit": "m", "index": 6, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.6096000075340271, "mean": 0.3284840874760239, "std": 0.1410640435394784 } } ], "georeference": null, "error": null, "chunks": { "shape": [512, 512], "count": null, "count_by_axis": null }, "tags": []}Record the new grid id (your-grid-id) and the grid you aligned to
(grid-to-align-to). Poll until completed:
curl -X 'GET' \ 'https://api.fastfuels.silvxlabs.com/v2/domains/your-domain-id/grids/your-grid-id' \ -H 'accept: application/json' \ -H 'api-key: my-api-key'import fastfuels_sdk.v2 as ff
ff.set_api_key("my-api-key")
grid = ff.get_grid("your-domain-id", "your-grid-id")grid.wait(){ "id": "your-grid-id", "domain_id": "your-domain-id", "name": "Surface fuel loads aligned to topography grid", "description": "", "status": "completed", "progress": { "percent": 100, "message": "Complete" }, "created_on": "2026-11-05T18:48:02.650716Z", "modified_on": "2026-11-05T18:48:06.461079Z", "checksum": "b66f28e77dc64056b4c28223a8f55a02", "source": { "name": "resample", "source_grid_id": "grid-to-resample", "method_overrides": {}, "source_grid_checksum": "dc891eb97b55438cb736bc90b73e74bd", "alignment": { "grid_id": "grid-to-align-to", "target": "grid", "resolution": null, "method": null } }, "modifications": [], "bands": [ { "key": "fuel_load.1hr", "name": "1-hour Fuel Load", "description": "Oven-dry mass per unit area of 1-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 0, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 1.3001821041107178, "mean": 0.31115281261162103, "std": 0.36798410696946504 } }, { "key": "fuel_load.10hr", "name": "10-hour Fuel Load", "description": "Oven-dry mass per unit area of 10-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 1, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.5367819666862488, "mean": 0.21739412592602944, "std": 0.1384398067589368 } }, { "key": "fuel_load.100hr", "name": "100-hour Fuel Load", "description": "Oven-dry mass per unit area of 100-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 2, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.33586007356643677, "mean": 0.11895392795390938, "std": 0.12499290535361296 } }, { "key": "fuel_load.dead_herb", "name": "Dead Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of cured herbaceous fuels. Takes the dead 1-hour fuel moisture.", "type": "continuous", "unit": "kg/m**2", "index": 3, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.150193452835083, "mean": 0.046225561941817234, "std": 0.041898759737492554 } }, { "key": "fuel_load.live_herb", "name": "Live Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of live herbaceous fuels: the uncured part of the herbaceous load.", "type": "continuous", "unit": "kg/m**2", "index": 4, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.07397587597370148, "mean": 0.022767810640240617, "std": 0.020636699443365627 } }, { "key": "fuel_load.live_woody", "name": "Live Woody Fuel Load", "description": "Oven-dry mass per unit area of live woody fuels.", "type": "continuous", "unit": "kg/m**2", "index": 5, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.8606133460998535, "mean": 0.12993971449668676, "std": 0.10108740905928758 } }, { "key": "fuel_depth", "name": "Fuel Bed Depth", "description": "Vertical depth of the surface fuel bed.", "type": "continuous", "unit": "m", "index": 6, "nodata": null, "summary": { "type": "continuous", "count": 19266, "nodata_count": 169, "min": 0.0, "max": 0.5923935770988464, "mean": 0.32813792104857026, "std": 0.12588202588448247 } } ], "georeference": { "crs": "EPSG:32611", "transform": [ 7.7301175133339015, 0.0, 720227.9398802927, 0.0, -7.730117513332516, 5190652.2875135 ], "shape": [115, 169] }, "error": null, "chunks": { "shape": [512, 512], "count": 1, "count_by_axis": { "x": 1, "y": 1 } }, "tags": []}The fuel grid comes back on the topography lattice (shape [115, 169],
≈7.73 m cells) — the same cell size, origin, and CRS as the target grid. The
two now share a grid and can be exported together.
Recipe B — resample to a target resolution
Section titled “Recipe B — resample to a target resolution”To set a cell size instead of matching another grid, set target: "domain"
and a resolution in meters. The output is anchored to
the domain origin.
curl -X 'POST' \ 'https://api.fastfuels.silvxlabs.com/v2/domains/your-domain-id/grids/resample' \ -H 'accept: application/json' \ -H 'api-key: my-api-key' \ -H 'Content-Type: application/json' \ -d '{ "name": "Surface fuel loads resampled to 10 m", "source_grid_id": "grid-to-resample", "alignment": { "target": "domain", "resolution": 10 }}'import fastfuels_sdk.v2 as ff
ff.set_api_key("my-api-key")
source_grid = ff.get_grid("your-domain-id", "grid-to-resample")
grid = source_grid.resample( output_resolution_m=10, name="Surface fuel loads resampled to 10 m",)grid.wait(){ "id": "your-grid-id", "domain_id": "your-domain-id", "name": "Surface fuel loads resampled to 10 m", "description": "", "status": "pending", "progress": null, "created_on": "2026-11-05T18:48:14.425590", "modified_on": "2026-11-05T18:48:14.425590", "checksum": "9069c7a6416f40a19f2640cb4f105121", "source": { "name": "resample", "source_grid_id": "grid-to-resample", "source_grid_checksum": "dc891eb97b55438cb736bc90b73e74bd", "alignment": { "target": "domain", "resolution": 10.0, "method": null }, "method_overrides": {} }, "modifications": [], "bands": [ { "key": "fuel_load.1hr", "name": "1-hour Fuel Load", "description": "Oven-dry mass per unit area of 1-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 0, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 1.3001821041107178, "mean": 0.3080750756200265, "std": 0.4163060013339203 } }, { "key": "fuel_load.10hr", "name": "10-hour Fuel Load", "description": "Oven-dry mass per unit area of 10-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 1, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.5380064249038696, "mean": 0.2154931436865418, "std": 0.149978944842402 } }, { "key": "fuel_load.100hr", "name": "100-hour Fuel Load", "description": "Oven-dry mass per unit area of 100-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 2, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.3362540006637573, "mean": 0.11744812236891852, "std": 0.1332688541789988 } }, { "key": "fuel_load.dead_herb", "name": "Dead Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of cured herbaceous fuels. Takes the dead 1-hour fuel moisture.", "type": "continuous", "unit": "kg/m**2", "index": 3, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.150193452835083, "mean": 0.04667122676140732, "std": 0.04506438979507076 } }, { "key": "fuel_load.live_herb", "name": "Live Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of live herbaceous fuels: the uncured part of the herbaceous load.", "type": "continuous", "unit": "kg/m**2", "index": 4, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.07397587597370148, "mean": 0.02298731718212366, "std": 0.022195890140762828 } }, { "key": "fuel_load.live_woody", "name": "Live Woody Fuel Load", "description": "Oven-dry mass per unit area of live woody fuels.", "type": "continuous", "unit": "kg/m**2", "index": 5, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.8630518913269043, "mean": 0.13079034814680063, "std": 0.11863219901758143 } }, { "key": "fuel_depth", "name": "Fuel Bed Depth", "description": "Vertical depth of the surface fuel bed.", "type": "continuous", "unit": "m", "index": 6, "nodata": null, "summary": { "type": "continuous", "count": 1350, "nodata_count": 0, "min": 0.0, "max": 0.6096000075340271, "mean": 0.3284840874760239, "std": 0.1410640435394784 } } ], "georeference": null, "error": null, "chunks": { "shape": [512, 512], "count": null, "count_by_axis": null }, "tags": []}{ "id": "your-grid-id", "domain_id": "your-domain-id", "name": "Surface fuel loads resampled to 10 m", "description": "", "status": "completed", "progress": { "percent": 100, "message": "Complete" }, "created_on": "2026-11-05T18:48:14.425590Z", "modified_on": "2026-11-05T18:48:17.964261Z", "checksum": "9069c7a6416f40a19f2640cb4f105121", "source": { "name": "resample", "source_grid_id": "grid-to-resample", "method_overrides": {}, "source_grid_checksum": "dc891eb97b55438cb736bc90b73e74bd", "alignment": { "target": "domain", "resolution": 10.0, "method": null } }, "modifications": [], "bands": [ { "key": "fuel_load.1hr", "name": "1-hour Fuel Load", "description": "Oven-dry mass per unit area of 1-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 0, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 1.3001821041107178, "mean": 0.3106236846174072, "std": 0.36770031799276204 } }, { "key": "fuel_load.10hr", "name": "10-hour Fuel Load", "description": "Oven-dry mass per unit area of 10-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 1, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.5315959453582764, "mean": 0.21717236787709057, "std": 0.13840196915076092 } }, { "key": "fuel_load.100hr", "name": "100-hour Fuel Load", "description": "Oven-dry mass per unit area of 100-hour timelag dead fuels.", "type": "continuous", "unit": "kg/m**2", "index": 2, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.2998290956020355, "mean": 0.11875496300239771, "std": 0.12493602537876013 } }, { "key": "fuel_load.dead_herb", "name": "Dead Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of cured herbaceous fuels. Takes the dead 1-hour fuel moisture.", "type": "continuous", "unit": "kg/m**2", "index": 3, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.150193452835083, "mean": 0.04629411523845225, "std": 0.04185866886318821 } }, { "key": "fuel_load.live_herb", "name": "Live Herbaceous Fuel Load", "description": "Oven-dry mass per unit area of live herbaceous fuels: the uncured part of the herbaceous load.", "type": "continuous", "unit": "kg/m**2", "index": 4, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.07397587597370148, "mean": 0.0228015756856236, "std": 0.020616953191922933 } }, { "key": "fuel_load.live_woody", "name": "Live Woody Fuel Load", "description": "Oven-dry mass per unit area of live woody fuels.", "type": "continuous", "unit": "kg/m**2", "index": 5, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.8532195091247559, "mean": 0.1301632582789756, "std": 0.10106408350503714 } }, { "key": "fuel_depth", "name": "Fuel Bed Depth", "description": "Vertical depth of the surface fuel bed.", "type": "continuous", "unit": "m", "index": 6, "nodata": null, "summary": { "type": "continuous", "count": 11528, "nodata_count": 131, "min": 0.0, "max": 0.5752248764038086, "mean": 0.3283030305883724, "std": 0.12552364231875926 } } ], "georeference": { "crs": "EPSG:32611", "transform": [10.0, 0.0, 720227.9398802927, 0.0, -10.0, 5190653.323999467], "shape": [89, 131] }, "error": null, "chunks": { "shape": [512, 512], "count": 1, "count_by_axis": { "x": 1, "y": 1 } }, "tags": []}Common pitfalls
Section titled “Common pitfalls”- Categorical bands averaged. If you resample an FBFM
(fuel-model code) grid with a continuous method, neighboring codes get
averaged into meaningless values. Let the default per-type method apply, or
set
nearestfor categorical bands. - Source grid not
completed. Resample reads the source grid’s data —source_grid_idmust point at a finished grid. - Reprojection. Resampling also reprojects when needed: output lands in
the domain CRS (or the target grid’s CRS for
target: "grid").