spatialdata.to_polygons#
- spatialdata.to_polygons(data, buffer_resolution=None)#
Convert a set of geometries (2D labels, 2D shapes) to approximated 2D polygons/multypolygons.
- Parameters:
data (
Union
[DataArray
,DataTree
,GeoDataFrame
,DataFrame
]) – The SpatialElement representing the geometries to approximate as 2D polygons/multipolygons.buffer_resolution (
Optional
[int
] (default:None
)) – Used only when constructing polygons from circles. Value of theresolution
parement for thebuffer()
internal call.
- Return type:
- Returns:
: The approximated 2D polygons/multipolygons in the specified coordinate system.