hydromt_sfincs.SfincsModel.setup_precip_forcing_from_grid#

SfincsModel.setup_precip_forcing_from_grid(precip, dst_res=None, aggregate=False, **kwargs)[source]#

Setup precipitation forcing from a gridded spatially varying data source.

If aggregate is True, spatially uniform precipitation forcing is added to the model based on the mean precipitation over the model domain. If aggregate is False, distributed precipitation is added to the model as netcdf file. The data is reprojected to the model CRS (and destination resolution dst_res if provided).

Adds one of these model layer:

  • netamprfile forcing: distributed precipitation [mm/hr]

  • precipfile forcing: uniform precipitation [mm/hr]

Parameters:
  • precip

    Path to precipitation rasterdataset netcdf file.

    • Required variables: [‘precip’ (mm)]

    • Required coordinates: [‘time’, ‘y’, ‘x’]

  • str

    Path to precipitation rasterdataset netcdf file.

    • Required variables: [‘precip’ (mm)]

    • Required coordinates: [‘time’, ‘y’, ‘x’]

  • Path

    Path to precipitation rasterdataset netcdf file.

    • Required variables: [‘precip’ (mm)]

    • Required coordinates: [‘time’, ‘y’, ‘x’]

  • dst_res (float) – output resolution (m), by default None and computed from source data. Only used in combination with aggregate=False

  • aggregate (bool, {'mean', 'median'}, optional) – Method to aggregate distributed input precipitation data. If True, mean aggregation is used, if False (default) the data is not aggregated and spatially distributed precipitation is returned.