gemgis.utils.set_extent
gemgis.utils.set_extent#
- gemgis.utils.set_extent(minx: Union[int, float] = 0, maxx: Union[int, float] = 0, miny: Union[int, float] = 0, maxy: Union[int, float] = 0, minz: Union[int, float] = 0, maxz: Union[int, float] = 0, gdf: geopandas.geodataframe.GeoDataFrame = None) List[Union[int, float]] #
Setting the extent for a model
- Parameters
minx (Union[int, float]) – Value defining the left border of the model, e.g.
minx=0
, default is0
maxx (Union[int, float]) – Value defining the right border of the model, e.g.
max=972
, default is0
miny (Union[int, float]) – Value defining the upper border of the model, e.g.
miny=0
, default is0
maxy (Union[int, float]) – Value defining the lower border of the model, e.g.
maxy=1069
, default is0
minz (Union[int, float]) – Value defining the top border of the model, e.g.
minz=0
, default is0
maxz (Union[int, float]) – Value defining the bottom border of the model, e.g.
maxz=1000
, default is0
gdf (gpd.geodataframe.GeoDataFrame) – GeoDataFrame from which bounds the extent will be set, default is
None
- Returns
extent – List containing extent values
- Return type
List[Union[int, float]]
New in version 1.0.x.
Example
>>> # Loading Libraries and setting the extent >>> import gemgis as gg >>> extent = gg.utils.set_extent(minx=0, maxx=972, miny=0, maxy=1069, minz=0, maxz=1000) >>> extent [0, 972, 0, 1069, 0, 1000]