Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion crates/analysis/src/parallel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,8 @@ pub(crate) fn for_each_row<T: Send, S>(
f(&mut s, i, row);
control::advance(1);
}
return Ok(());
// A cancel raised during the last row left its cell unwritten: as after the threads join below.
return control::check();
}
let run = control::current();
let plane = crate::convert::run_plane();
Expand Down
274 changes: 260 additions & 14 deletions crates/analysis/src/tools.rs

Large diffs are not rendered by default.

352 changes: 316 additions & 36 deletions crates/analysis/src/warp.rs

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions crates/engine/src/tests/cancellation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,7 @@ pub(super) fn long_commands(boundaries: bool) {
("convexHull", json!({"input": "Countries", "group": "None", "output": "Hulls_each"})),
("convexHull", json!({"input": "Countries", "group": "All", "output": "Hulls_all"})),
("kernelDensity", json!({"input": "Cities", "crs": "EPSG:3857", "pixelSize": if boundaries { 2000 } else { 1000000 }})),
("idwInterpolation", json!({"input": "Cities", "field": "pop_max", "pixelSize": if boundaries { 0.01 } else { 1.0 }})),
("kriging", json!({"input": "Cities", "field": "pop_max", "pixelSize": if boundaries { 0.01 } else { 1.0 }})),
("tabulateArea", json!({"raster": dem, "zones": "Countries"})),
("tabulateIntersection", json!({"zones": "Countries", "classes": "Squares", "includeEmptyZones": true})),
Expand Down
17 changes: 13 additions & 4 deletions docs/user-guide/analysis.md
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,10 @@ gp.run={"tool":"pointsAlongLines","params":{"input":"Rivers","distance":500,"uni
cell by 1/distanceᴾ, where P is the distance coefficient (2 by default). Lines and polygons
contribute their vertices. Leave the extent empty to use the input's, or give it as
`xmin,ymin,xmax,ymax`. `pixelSize` sets the cell size; when omitted it starts at 300 cells
across the extent and coarsens for large inputs. The result is a Float32 GeoTIFF layer. The
across the extent and coarsens for large inputs. The result is a Float32 GeoTIFF layer. Features
with no geometry, or whose field isn't a finite number, and coordinates that aren't finite numbers,
are left out and said, once for each kind with its count (`dropped.feature`, `dropped.geometry`);
when fewer than two points are left, the error says how many were left out. The
**Geostatistical Wizard** is a separate IDW workflow, with its coordinate system from Environments
(below): it uses 12 nearest neighbours by default (`neighbors`), rather than every point.

Expand All @@ -790,8 +793,10 @@ override the defaults: zero nugget, the sample variance (1 for near-constant val
third of the extent's diagonal. `range`, `extent` and `pixelSize` are in the units of `crs`, or
in degrees without it (see above). Points at the same location are averaged; multipoints
contribute their points, while lines and polygons contribute their bounding-box centres. At least
two distinct locations with numeric values are needed. It adds **two separate Float32 GeoTIFF
layers**: the prediction, named by `output`, and `<output>_variance`.
two distinct locations with numeric values are needed. Features with no geometry or no numeric
value, and coordinates that aren't finite numbers, are left out and said, as for IDW
Interpolation. It adds **two separate Float32 GeoTIFF layers**: the prediction, named by
`output`, and `<output>_variance`.

**Clip** (`clip`) keeps the parts of `input` inside the `clip` polygons. It gives one notice with
the count of output polygon features whose total area is less than one millionth (`1e-6`) of
Expand Down Expand Up @@ -2157,7 +2162,11 @@ commands described here aren't on the tab or part of the extension, and run whet
value (of those tied, the one that reaches the top count first, the pixels taken row by row, as
in GDAL), which is what a coarser grid of elevation or land-cover classes should hold. A
cell no pixel centre falls in, on a grid finer than the raster, takes the pixel under its
centre. Classes take `nearest` or `mode`, continuous values `bilinear` or `cubic`, or `average`
centre. A cell across the antimeridian of a source that spans -180° to 180° takes the pixels on
both sides of it (in an output whose x grows eastward; a cell over half the globe wide in one
that runs east to west can't be told from one across it). A source that runs from 0° to 360°
is not wrapped, and `bilinear` and `cubic` still clamp at the seam instead of reading across
it. Classes take `nearest` or `mode`, continuous values `bilinear` or `cubic`, or `average`
going coarser. A whole-number pixel type keeps its type, so its mean is rounded. On a colour
image the colours count as much as their pixels are opaque, and `mode` is taken band by band
(each channel's most frequent value among the pixels that show). Class names are kept with
Expand Down
2 changes: 1 addition & 1 deletion xtask/row-uses.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
# down: new code reads and changes rows through the accessors on `Features`
# (crates/data/src/row_access.rs). When a change lowers it, run `cargo xtask rows --update` and
# commit this file with it.
count = 764
count = 760
Loading