mirror of
https://github.com/qurator-spk/eynollah.git
synced 2025-11-09 22:24:13 +01:00
try with shapely.set_precision(...mode="keep_collpased")
This commit is contained in:
parent
0d84e7da16
commit
d224b0f7e8
1 changed files with 1 additions and 1 deletions
|
|
@ -357,7 +357,7 @@ def join_polygons(polygons: Sequence[Polygon], scale=20) -> Polygon:
|
|||
assert jointp.geom_type == 'Polygon', jointp.wkt
|
||||
# follow-up calculations will necessarily be integer;
|
||||
# so anticipate rounding here and then ensure validity
|
||||
jointp2 = set_precision(jointp, 1.0)
|
||||
jointp2 = set_precision(jointp, 1.0, mode="keep_collapsed")
|
||||
if jointp2.geom_type != 'Polygon' or not jointp2.is_valid:
|
||||
jointp2 = Polygon(np.round(jointp.exterior.coords))
|
||||
jointp2 = make_valid(jointp2)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue