hydromt_wflow.WflowModel.setup_allocation_surfacewaterfrac#

WflowModel.setup_allocation_surfacewaterfrac(gwfrac_fn: str | DataArray, waterareas_fn: str | DataArray | None = None, gwbodies_fn: str | DataArray | None = None, ncfrac_fn: str | DataArray | None = None, interpolate_nodata: bool = False, mask_and_scale_gwfrac: bool = True)[source]#

Create the fraction of water allocated from surface water.

This fraction entails the division of the water demand between surface water, ground water (aquifers) and non conventional sources (e.g. desalination plants).

The surface water fraction is based on the raw groundwater fraction, if groundwater bodies are present (these are absent in e.g. mountainous regions), a fraction of water consumed that is obtained by non-conventional means and the water source areas.

Non-conventional water could e.g. be water acquired by desalination of ocean or other brackish water.

Adds model layer:

  • frac_sw_used: fraction of water allocated from surface water [0-1]

Parameters:
  • gwfrac_fn (Union[str, xr.DataArray]) – The raw groundwater fraction per grid cell. The values of these cells need to be between 0 and 1.

  • waterareas_fn (Union[str, xr.DataArray]) – The areas over which the water has to be distributed. This may either be a global (or more local map). If not provided, the source areas created by the setup_allocation_areas will be used.

  • gwbodies_fn (Union[str, xr.DataArray], optional) – The presence of groundwater bodies per grid cell. The values are ought to be binary (either 0 or 1). If they are not provided, we assume groundwater bodies are present where gwfrac is more than 0.

  • ncfrac_fn (Union[str, xr.DataArray], optional) – The non-conventional fraction. Same types of values apply as for gwfrac_fn. If not provided, we assume no non-conventional sources are used.

  • interpolate_nodata (bool, optional) – If True, nodata values in the resulting frac_sw_used map will be linearly interpolated. Else a default value of 1 will be used for nodata values (default).

  • mask_and_scale_gwfrac (bool, optional) – If True, gwfrac will be masked for areas with no groundwater bodies. To keep the average gwfrac used over waterareas similar after the masking, gwfrac for areas with groundwater bodies can increase. If False, gwfrac will be used as is. By default True.