cartagen.collapse_roundabouts

cartagen.collapse_roundabouts#

collapse_roundabouts(roads, roundabouts, crossroads=None, maximum_diameter=None)#

Collapse roundabouts to a point.

This algorithm proposed by Touya [1] collapses roundabouts to a point if their diameter is below the given value.

Parameters:
  • roads (GeoDataFrame of LineString) – Road network where roundabouts will be collapsed.

  • roundabouts (GeoDataFrame of Polygon) – Polygons representing the faces of the network detected as roundabouts.

  • crossroads (GeoDataFrame of Polygon, optional) – Polygons representing the faces of the network detected as branching crossroads. This allows incoming branching crossroads on roundabouts to be collapsed as well.

  • maximum_diameter (float, optional) – Diameter, in meter, below which roundabouts are collapsed. Collpase all roundabouts if left to None.

Returns:

GeoDataFrame of LineString

Warning

Detecting branching crossroads beforehand is important as a branching crossroad may be an entrance to a roundabout. This algorithm will collapse the roundabout as well as all its connected branching crossroads.

See also

detect_roundabouts

Detect roundabouts inside the road network.

detect_branching_crossroads

Detect branching crossroads inside the road network.

collapse_branching_crossroads

Collapse branching crossroads to a point.

References

(Source code)

../_images/collapse_roundabouts.png