sertit.rasters.slope¶
- slope(xds: Union[str, xarray.core.dataarray.DataArray, xarray.core.dataset.Dataset, rasterio.io.DatasetReader], in_pct: bool = False, in_rad: bool = False) Union[xarray.core.dataset.Dataset, xarray.core.dataarray.DataArray] [source]¶
Compute the slope of a DEM (in degrees).
Goal: replace gdaldem CLI (https://gdal.org/programs/gdaldem.html)
NB: altitude = zenith
- Parameters
dst (PATH_XARR_DS) – Path to the raster, its dataset, its xarray or a tuple containing its array and metadata
- Returns
Slope
- Return type
XDS_TYPE