geo-polygonize 0.36.2 → 0.39.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -0
- package/dist/geo_polygonize.wasm +0 -0
- package/dist/geo_polygonize_simd.wasm +0 -0
- package/dist/slim/cjs/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/slim/cjs/bindings/SnapStrategy.d.ts +9 -19
- package/dist/slim/cjs/index.d.ts +0 -1
- package/dist/slim/cjs/index_slim.d.ts +0 -1
- package/dist/slim/cjs/index_threads.d.ts +0 -1
- package/dist/slim/es/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/slim/es/bindings/SnapStrategy.d.ts +9 -19
- package/dist/slim/es/index.d.ts +0 -1
- package/dist/slim/es/index_slim.d.ts +0 -1
- package/dist/slim/es/index_threads.d.ts +0 -1
- package/dist/slim/pkg-wrapper/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/slim/pkg-wrapper/bindings/SnapStrategy.d.ts +9 -19
- package/dist/standard/cjs/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/standard/cjs/bindings/SnapStrategy.d.ts +9 -19
- package/dist/standard/cjs/index.d.ts +0 -1
- package/dist/standard/cjs/index.js +2 -2
- package/dist/standard/cjs/index_slim.d.ts +0 -1
- package/dist/standard/cjs/index_threads.d.ts +0 -1
- package/dist/standard/es/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/standard/es/bindings/SnapStrategy.d.ts +9 -19
- package/dist/standard/es/index.d.ts +0 -1
- package/dist/standard/es/index.js +2 -2
- package/dist/standard/es/index_slim.d.ts +0 -1
- package/dist/standard/es/index_threads.d.ts +0 -1
- package/dist/standard/pkg-wrapper/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/standard/pkg-wrapper/bindings/SnapStrategy.d.ts +9 -19
- package/dist/threads/es/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/threads/es/bindings/SnapStrategy.d.ts +9 -19
- package/dist/threads/es/index.d.ts +0 -1
- package/dist/threads/es/index_slim.d.ts +0 -1
- package/dist/threads/es/index_threads.d.ts +0 -1
- package/dist/threads/pkg-wrapper/bindings/PolygonizerOptions.d.ts +1 -1
- package/dist/threads/pkg-wrapper/bindings/SnapStrategy.d.ts +9 -19
- package/package.json +1 -1
- package/dist/slim/cjs/bindings/TilingOptions.d.ts +0 -6
- package/dist/slim/es/bindings/TilingOptions.d.ts +0 -6
- package/dist/slim/pkg-wrapper/bindings/TilingOptions.d.ts +0 -6
- package/dist/standard/cjs/bindings/TilingOptions.d.ts +0 -6
- package/dist/standard/es/bindings/TilingOptions.d.ts +0 -6
- package/dist/standard/pkg-wrapper/bindings/TilingOptions.d.ts +0 -6
- package/dist/threads/es/bindings/TilingOptions.d.ts +0 -6
- package/dist/threads/pkg-wrapper/bindings/TilingOptions.d.ts +0 -6
package/README.md
CHANGED
|
@@ -145,6 +145,12 @@ The default return shape is a stable dictionary with `polygons` as
|
|
|
145
145
|
`SimplePolygon` values. Use `return_polygons=True` only when you want Shapely
|
|
146
146
|
`Polygon` objects.
|
|
147
147
|
|
|
148
|
+
`SnapStrategy::Grid` keeps topology and output coordinates on the configured
|
|
149
|
+
precision grid. The CFB profile uses `GeosCompat`: the grid establishes robust
|
|
150
|
+
topology, then output nodes regain deterministic source coordinates to better
|
|
151
|
+
match Shapely `snap` plus full-precision noding. It is not `set_precision`
|
|
152
|
+
emulation, and exact parity is not guaranteed for many-to-one snaps.
|
|
153
|
+
|
|
148
154
|
For Shapely parity checks, compare report-mode outputs with the built-in
|
|
149
155
|
mismatch helper:
|
|
150
156
|
|
package/dist/geo_polygonize.wasm
CHANGED
|
Binary file
|
|
Binary file
|
|
@@ -49,7 +49,7 @@ export type PolygonizerOptions = {
|
|
|
49
49
|
*/
|
|
50
50
|
extract_only_polygonal: boolean;
|
|
51
51
|
/**
|
|
52
|
-
*
|
|
52
|
+
* Controls robust snap noding and output coordinate handling.
|
|
53
53
|
*
|
|
54
54
|
* See `SnapStrategy` for differences between strict `Grid` snapping and
|
|
55
55
|
* Shapely/GEOS `GeosCompat` strategies.
|
|
@@ -1,25 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Strategy for
|
|
2
|
+
* Strategy for robust snap noding and output coordinates.
|
|
3
3
|
*
|
|
4
|
-
* `Grid`
|
|
5
|
-
* `GeosCompat`
|
|
6
|
-
*
|
|
4
|
+
* `Grid` uses the precision grid for both topology and output coordinates.
|
|
5
|
+
* `GeosCompat` uses the grid for topology, then restores one deterministic nearest source
|
|
6
|
+
* coordinate per snapped node. This targets Shapely-style `snap` followed by full-precision
|
|
7
|
+
* noding and polygonization; it does not emulate `set_precision` output.
|
|
7
8
|
*
|
|
8
9
|
* **Scale Guidance:**
|
|
9
|
-
* Use `Grid`
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* **Expected Parity:**
|
|
15
|
-
* Rust's native `f64::round()` rounds halfway cases away from zero. This perfectly
|
|
16
|
-
* matches C++ `std::round` behavior, meaning that `Grid` and `GeosCompat` currently
|
|
17
|
-
* map identical values for basic single-coordinate precision points (e.g., `-0.5` => `-1.0`
|
|
18
|
-
* and `0.5` => `1.0`).
|
|
19
|
-
*
|
|
20
|
-
* **Expected Divergence:**
|
|
21
|
-
* The divergence between `Grid` and `GeosCompat` strategies typically arises under complex
|
|
22
|
-
* topological scaling sequences rather than simple single point coordinate rounding, but
|
|
23
|
-
* the option ensures the library remains semantically compatible with Python/C++ GEOS pipelines.
|
|
10
|
+
* Use `Grid` when an explicit precision model is the desired output contract.
|
|
11
|
+
* Use `GeosCompat` when the grid is a robustness aid but source-coordinate fidelity matters.
|
|
12
|
+
* Both strategies are deterministic; exact GEOS/Shapely parity is not guaranteed for
|
|
13
|
+
* degenerate or many-to-one snaps.
|
|
24
14
|
*/
|
|
25
15
|
export type SnapStrategy = "Grid" | "GeosCompat";
|
package/dist/slim/cjs/index.d.ts
CHANGED
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export default function init(_input?: any): Promise<typeof exports>;
|
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export declare function initBest(scalarModule: any, simdModule?: any): Promise<typeof scalarExports>;
|
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export default init;
|
|
@@ -49,7 +49,7 @@ export type PolygonizerOptions = {
|
|
|
49
49
|
*/
|
|
50
50
|
extract_only_polygonal: boolean;
|
|
51
51
|
/**
|
|
52
|
-
*
|
|
52
|
+
* Controls robust snap noding and output coordinate handling.
|
|
53
53
|
*
|
|
54
54
|
* See `SnapStrategy` for differences between strict `Grid` snapping and
|
|
55
55
|
* Shapely/GEOS `GeosCompat` strategies.
|
|
@@ -1,25 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Strategy for
|
|
2
|
+
* Strategy for robust snap noding and output coordinates.
|
|
3
3
|
*
|
|
4
|
-
* `Grid`
|
|
5
|
-
* `GeosCompat`
|
|
6
|
-
*
|
|
4
|
+
* `Grid` uses the precision grid for both topology and output coordinates.
|
|
5
|
+
* `GeosCompat` uses the grid for topology, then restores one deterministic nearest source
|
|
6
|
+
* coordinate per snapped node. This targets Shapely-style `snap` followed by full-precision
|
|
7
|
+
* noding and polygonization; it does not emulate `set_precision` output.
|
|
7
8
|
*
|
|
8
9
|
* **Scale Guidance:**
|
|
9
|
-
* Use `Grid`
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* **Expected Parity:**
|
|
15
|
-
* Rust's native `f64::round()` rounds halfway cases away from zero. This perfectly
|
|
16
|
-
* matches C++ `std::round` behavior, meaning that `Grid` and `GeosCompat` currently
|
|
17
|
-
* map identical values for basic single-coordinate precision points (e.g., `-0.5` => `-1.0`
|
|
18
|
-
* and `0.5` => `1.0`).
|
|
19
|
-
*
|
|
20
|
-
* **Expected Divergence:**
|
|
21
|
-
* The divergence between `Grid` and `GeosCompat` strategies typically arises under complex
|
|
22
|
-
* topological scaling sequences rather than simple single point coordinate rounding, but
|
|
23
|
-
* the option ensures the library remains semantically compatible with Python/C++ GEOS pipelines.
|
|
10
|
+
* Use `Grid` when an explicit precision model is the desired output contract.
|
|
11
|
+
* Use `GeosCompat` when the grid is a robustness aid but source-coordinate fidelity matters.
|
|
12
|
+
* Both strategies are deterministic; exact GEOS/Shapely parity is not guaranteed for
|
|
13
|
+
* degenerate or many-to-one snaps.
|
|
24
14
|
*/
|
|
25
15
|
export type SnapStrategy = "Grid" | "GeosCompat";
|
package/dist/slim/es/index.d.ts
CHANGED
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export default function init(_input?: any): Promise<typeof exports>;
|
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export declare function initBest(scalarModule: any, simdModule?: any): Promise<typeof scalarExports>;
|
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export default init;
|
|
@@ -49,7 +49,7 @@ export type PolygonizerOptions = {
|
|
|
49
49
|
*/
|
|
50
50
|
extract_only_polygonal: boolean;
|
|
51
51
|
/**
|
|
52
|
-
*
|
|
52
|
+
* Controls robust snap noding and output coordinate handling.
|
|
53
53
|
*
|
|
54
54
|
* See `SnapStrategy` for differences between strict `Grid` snapping and
|
|
55
55
|
* Shapely/GEOS `GeosCompat` strategies.
|
|
@@ -1,25 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Strategy for
|
|
2
|
+
* Strategy for robust snap noding and output coordinates.
|
|
3
3
|
*
|
|
4
|
-
* `Grid`
|
|
5
|
-
* `GeosCompat`
|
|
6
|
-
*
|
|
4
|
+
* `Grid` uses the precision grid for both topology and output coordinates.
|
|
5
|
+
* `GeosCompat` uses the grid for topology, then restores one deterministic nearest source
|
|
6
|
+
* coordinate per snapped node. This targets Shapely-style `snap` followed by full-precision
|
|
7
|
+
* noding and polygonization; it does not emulate `set_precision` output.
|
|
7
8
|
*
|
|
8
9
|
* **Scale Guidance:**
|
|
9
|
-
* Use `Grid`
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* **Expected Parity:**
|
|
15
|
-
* Rust's native `f64::round()` rounds halfway cases away from zero. This perfectly
|
|
16
|
-
* matches C++ `std::round` behavior, meaning that `Grid` and `GeosCompat` currently
|
|
17
|
-
* map identical values for basic single-coordinate precision points (e.g., `-0.5` => `-1.0`
|
|
18
|
-
* and `0.5` => `1.0`).
|
|
19
|
-
*
|
|
20
|
-
* **Expected Divergence:**
|
|
21
|
-
* The divergence between `Grid` and `GeosCompat` strategies typically arises under complex
|
|
22
|
-
* topological scaling sequences rather than simple single point coordinate rounding, but
|
|
23
|
-
* the option ensures the library remains semantically compatible with Python/C++ GEOS pipelines.
|
|
10
|
+
* Use `Grid` when an explicit precision model is the desired output contract.
|
|
11
|
+
* Use `GeosCompat` when the grid is a robustness aid but source-coordinate fidelity matters.
|
|
12
|
+
* Both strategies are deterministic; exact GEOS/Shapely parity is not guaranteed for
|
|
13
|
+
* degenerate or many-to-one snaps.
|
|
24
14
|
*/
|
|
25
15
|
export type SnapStrategy = "Grid" | "GeosCompat";
|
|
@@ -49,7 +49,7 @@ export type PolygonizerOptions = {
|
|
|
49
49
|
*/
|
|
50
50
|
extract_only_polygonal: boolean;
|
|
51
51
|
/**
|
|
52
|
-
*
|
|
52
|
+
* Controls robust snap noding and output coordinate handling.
|
|
53
53
|
*
|
|
54
54
|
* See `SnapStrategy` for differences between strict `Grid` snapping and
|
|
55
55
|
* Shapely/GEOS `GeosCompat` strategies.
|
|
@@ -1,25 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Strategy for
|
|
2
|
+
* Strategy for robust snap noding and output coordinates.
|
|
3
3
|
*
|
|
4
|
-
* `Grid`
|
|
5
|
-
* `GeosCompat`
|
|
6
|
-
*
|
|
4
|
+
* `Grid` uses the precision grid for both topology and output coordinates.
|
|
5
|
+
* `GeosCompat` uses the grid for topology, then restores one deterministic nearest source
|
|
6
|
+
* coordinate per snapped node. This targets Shapely-style `snap` followed by full-precision
|
|
7
|
+
* noding and polygonization; it does not emulate `set_precision` output.
|
|
7
8
|
*
|
|
8
9
|
* **Scale Guidance:**
|
|
9
|
-
* Use `Grid`
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
* **Expected Parity:**
|
|
15
|
-
* Rust's native `f64::round()` rounds halfway cases away from zero. This perfectly
|
|
16
|
-
* matches C++ `std::round` behavior, meaning that `Grid` and `GeosCompat` currently
|
|
17
|
-
* map identical values for basic single-coordinate precision points (e.g., `-0.5` => `-1.0`
|
|
18
|
-
* and `0.5` => `1.0`).
|
|
19
|
-
*
|
|
20
|
-
* **Expected Divergence:**
|
|
21
|
-
* The divergence between `Grid` and `GeosCompat` strategies typically arises under complex
|
|
22
|
-
* topological scaling sequences rather than simple single point coordinate rounding, but
|
|
23
|
-
* the option ensures the library remains semantically compatible with Python/C++ GEOS pipelines.
|
|
10
|
+
* Use `Grid` when an explicit precision model is the desired output contract.
|
|
11
|
+
* Use `GeosCompat` when the grid is a robustness aid but source-coordinate fidelity matters.
|
|
12
|
+
* Both strategies are deterministic; exact GEOS/Shapely parity is not guaranteed for
|
|
13
|
+
* degenerate or many-to-one snaps.
|
|
24
14
|
*/
|
|
25
15
|
export type SnapStrategy = "Grid" | "GeosCompat";
|
|
@@ -9,7 +9,6 @@ export * from "./bindings/NodingOptions";
|
|
|
9
9
|
export * from "./bindings/ProvenanceOptions";
|
|
10
10
|
export * from "./bindings/SnapStrategy";
|
|
11
11
|
export * from "./bindings/TileOwnershipPolicy";
|
|
12
|
-
export * from "./bindings/TilingOptions";
|
|
13
12
|
export * from "./bindings/TouchPolicy";
|
|
14
13
|
export * from "./cfb";
|
|
15
14
|
export default function init(_input?: any): Promise<typeof exports>;
|