Quick overview#

Typically, we use HydroMT together with a plugin to build a model from scratch. Here, we illustrate this for the Wflow rainfall-runoff model, but the procedure is identical for other models.

Install HydroMT & model plugin#

If you haven’t already done so, first install HydroMT and the HydroMT-Wflow plugin in a new hydromt environment and activate this environment. For more information about the installation, please refer to the installation guide.

$ conda create -n hydromt -c conda-forge python=3.9 hydromt hydromt_wflow
$ conda activate hydromt

Next, check if the installation was successful by running the command below. This returns the available models for HydroMT and should at least contain wflow and wflow_sediment.

$ hydromt --models

>> hydroMT model plugins: wflow (vx.x.x), wflow_sediment (vx.x.x)

Build a model#

Now you can create a model from raw data. To do so, you need to define

  1. the source data: To try out HydroMT, you can make use of the publicly available HydroMT artifacts data catalog which contains data for the Piave basin in Northern Italy and is the default catalog if no other one is specified.

  2. the model region: There are many options to define the region. In this example the model region is defined by the Piave subbasin upstream from an outlet point defined: "{'subbasin': [12.2051, 45.8331], 'strord': 4}"

  3. the model setup configuration: Finally, the model setup needs to be configured. Here, the example configuration from the HydroMT-Wflow repository is used. You can download the ini file here (right click & save as) and save it in the current directory. For information about specific options, please visit the documentation of the HydroMT plugin of your model of interest.

These steps are combined into the following command which saves all Wflow model files and a hydromt.log file in the wflow_test folder. This Wflow model instance is ready to be run with Wflow.

$ hydromt build wflow ./wflow_test "{'subbasin': [12.2051, 45.8331], 'strord': 4}" -vv -i build_wflow.ini