cityImage.polygonise_partitions#

cityImage.polygonise_partitions(edges_gdf, column, convex_hull=True, buffer=30)[source]#

Given districts assign to street segments it create polygons representing districts, either by creating a convex_hull for each group of segments or simply polygonising them.

Parameters:
  • edges_gdf (LineString GeoDataFrame) – The street segments GeoDataFrame.

  • column (string) – The name of the column containing the district identifier.

  • convex_hull (boolean) – When True creates create convex hulls after having polygonised the cluster of segments.

  • buffer (float) – Desired buffer around the polygonised segments, before possibly obtaining the convex hulls.

Returns:

polygonised_partitions – A GeoDataFrame containing the polygonised partitions.

Return type:

Polygon GeoDataFrame