hydromt_sfincs.SfincsModel.setup_river_outflow#

SfincsModel.setup_river_outflow(rivers: str | Path | GeoDataFrame = None, hydrography: str | Path | Dataset = None, river_upa: float = 10.0, river_len: float = 1000.0, river_width: float = 500, keep_rivers_geom: bool = False, reset_bounds: bool = False, btype: str = 'outflow', reverse_river_geom: bool = False)[source]#

Setup open boundary cells (mask=3) where a river flows out of the model domain.

If rivers is not provided, river centerlines are extracted from the hydrography dataset based on the river_upa threshold.

River outflows that intersect with discharge source point or waterlevel boundary cells are omitted.

Note: this method assumes the rivers are directed from up- to downstream.

Adds / edits model layers:

  • msk map: edited by adding outflow points (msk=3)

  • rivers_outflow geoms: river centerline (if keep_rivers_geom; not used by SFINCS)

Parameters:
  • rivers (str, Path, gpd.GeoDataFrame, optional) – Path, data source name, or geopandas object for river centerline data. If present, the ‘uparea’ and ‘rivlen’ attributes are used.

  • hydrography (str, Path, xr.Dataset optional) –

    Path, data source name, or a xarray raster object for hydrography data.

    • Required layers: [‘uparea’, ‘flwdir’].

  • river_upa (float, optional) – Minimum upstream area threshold for rivers [km2], by default 10.0

  • river_len (float, optional) – Mimimum river length within the model domain threshhold [m], by default 1000 m.

  • river_width (int, optional) – The width [m] of the open boundary cells in the SFINCS msk file. By default 500m, i.e.: 250m to each side of the outflow location.

  • append_bounds (bool, optional) – If True, write new outflow boundary cells on top of existing. If False (default), first reset existing outflow boundary cells to normal active cells.

  • keep_rivers_geom (bool, optional) – If True, keep a geometry of the rivers “rivers_outflow” in geoms. By default False.

  • reset_bounds (bool, optional) – If True, reset existing outlfow boundary cells before setting new boundary cells, by default False.

  • btype ({'waterlevel', 'outflow'}) – Boundary type

  • reverse_river_geom (bool, optional) – If True, assume that segments in ‘rivers’ are drawn from downstream to upstream. Only used if rivers is not None, By default False