neatnet.neatify_singletons#
- neatnet.neatify_singletons(artifacts, streets, *, max_segment_length=1, compute_coins=True, angle_threshold=120, min_dangle_length=10, eps=0.0001, clip_limit=2, simplification_factor=2, consolidation_tolerance=10)[source]#
Simplification of singleton face artifacts – the first simplification step in the procedure detailed in
simplify.neatify_loop().This process extracts nodes from network edges before computing and labeling face artifacts with a
{C, E, S}typology throughmomepy.COINSvia the constituent street geometries.Next, each artifact is iterated over and constituent line geometries are either dropped or added in the following order of typologies:
1 node and 1 continuity group
more than 1 node and 1 or more identical continuity groups
2 or more nodes and 2 or more continuity groups
Non-planar geometries are ignored.
- Parameters:
- artifacts
geopandas.GeoDataFrame Face artifact polygons.
- streets
geopandas.GeoDataFrame Preprocessed street network data.
- max_segment_length
float|int= 1 Additional nodes will be added so that all line segments are no longer than this value. Must be greater than 0. Used in multiple internal geometric operations.
- compute_coinsbool =
True Flag for computing and labeling artifacts with a
{C, E, S}typology throughmomepy.COINSvia the constituent street geometries.- angle_threshold
float= 120 See the
angle_thresholdkeyword argument inmomepy.COINS.- min_dangle_length
float|int= 10 The threshold for determining if linestrings are dangling slivers to be removed or not.
- eps
float= 1e-4 Tolerance epsilon used in multiple internal geometric operations.
- clip_limit
float|int= 2 Following generation of the Voronoi linework, we clip to fit inside the polygon. To ensure we get a space to make proper topological connections from the linework to the actual points on the edge of the polygon, we clip using a polygon with a negative buffer of
clip_limitor the radius of maximum inscribed circle, whichever is smaller.- simplification_factor
float|int= 2 The factor by which singles, pairs, and clusters are simplified. The
max_segment_lengthis multiplied by this factor to get the simplification epsilon.- consolidation_tolerance
float|int= 10 Tolerance passed to node consolidation when generating Voronoi skeletons.
- artifacts
- Returns:
geopandas.GeoDataFrameThe street network line data following the singleton procedure.