-
Notifications
You must be signed in to change notification settings - Fork 69
Description
Describe the problem
Running morphological_tessellation on some island coastlines, there were some strange artefacts in the output where the channel was <100m wide.
Input island coastlines.
Tessellation output overlaid on the coastlines, the narrow point is around 60m wide.
Steps to reproduce
import geopandas
import momepy
coastline = "path/to/coastline.shp"
polygons = "path/to/output.shp"
coast_gdf = geopandas.read_file(coastline).reset_index(drop=True)
result = momepy.morphological_tessellation(coast_gdf, segment=500, shrink=20)
result.to_file(polygons)Versions of your packages
python=3.12.11
momepy=0.9.1
geopandas=1.1.1
libpysal=4.13.0
networkx=3.5
Your operating system
Ubuntu 22.04.5 LTS
Additional context
Having reread the doc, I can see the values we were using for segment and shrink are way off the default values. They had been working for us up to that point. When I lowered the segment value to 100, the issue went away.
So, you can probably close this issue as being user error, but could I ask for a clarification in the docs? Both segment and shrink represent a distance, but is this map units? I'm assuming it is, but it would be good to clarify it, as it could be pixels or something else.