hydromt_sfincs.SfincsModel.setup_bounds

SfincsModel.setup_bounds(btype='waterlevel', mask_fn=None, include_mask_fn=None, exclude_mask_fn=None, elv_min=None, elv_max=None, mask_buffer=0, connectivity=8, reset_bounds=False)[source]

Set boundary cells in the model mask.

The SFINCS model mask defines 0) Inactive, 1) active, and 2) waterlevel boundary and 3) outflow boundary cells. Active cells set using the setup_mask method, while this method sets both types of boundary cells, see btype argument.

Boundary cells at the edge of the active model domain, optionally bounded by areas inside the include geomtries, outside the exclude geomtries, larger or equal than a minimum elevation threshhold and smaller or equal than a maximum elevation threshhold. All conditions are combined using a logical AND operation.

Updates model layers:

  • msk map: model mask [-]

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

  • mask_fn (str, optional) – Path or data source name of polygons describing the initial region constraining model boundary cells.

  • include_mask_fn (str, optional) – Path or data source name for geometries with areas to include/exclude from the model boundary. Note that exclude (second last) and include (last) areas are processed after other critera, i.e. elv_min, elv_max, and thus overrule these criteria for model boundary cells.

  • exclude_mask_fn (str, optional) – Path or data source name for geometries with areas to include/exclude from the model boundary. Note that exclude (second last) and include (last) areas are processed after other critera, i.e. elv_min, elv_max, and thus overrule these criteria for model boundary cells.

  • elv_min (float, optional) – Minimum and maximum elevation thresholds for boundary cells.

  • elv_max (float, optional) – Minimum and maximum elevation thresholds for boundary cells.

  • mask_buffer (float, optional) – If larger than zero, extend the mask_fn geometry with a buffer [m], by default 0.

  • reset_bounds (bool, optional) – If True, reset existing boundary cells of the selected boundary type (btype) before setting new boundary cells, by default False.

  • connectivity – The connectivity used to detect the model edge, if 4 only horizontal and vertical connections are used, if 8 (default) also diagonal connections.

  • {4 – The connectivity used to detect the model edge, if 4 only horizontal and vertical connections are used, if 8 (default) also diagonal connections.

  • 8} – The connectivity used to detect the model edge, if 4 only horizontal and vertical connections are used, if 8 (default) also diagonal connections.