geopandas.GeoSeries.boundary#
- property GeoSeries.boundary[来源]#
返回一个
GeoSeries,其中包含每个几何体的集合论 边界 的低维对象。另请参阅
GeoSeries.exterior外部边界(不包括内部环)
示例
>>> from shapely.geometry import Polygon, LineString, Point >>> s = geopandas.GeoSeries( ... [ ... Polygon([(0, 0), (1, 1), (0, 1)]), ... LineString([(0, 0), (1, 1), (1, 0)]), ... Point(0, 0), ... ] ... ) >>> s 0 POLYGON ((0 0, 1 1, 0 1, 0 0)) 1 LINESTRING (0 0, 1 1, 1 0) 2 POINT (0 0) dtype: geometry
>>> s.boundary 0 LINESTRING (0 0, 1 1, 0 1, 0 0) 1 MULTIPOINT ((0 0), (1 0)) 2 GEOMETRYCOLLECTION EMPTY dtype: geometry