Skip to content

Account for nested subcatchments when writing output #807

@JoostBuitink

Description

@JoostBuitink

Feature type

Adding new functionality

Improvement Description

Right now, we support averaging model variables to subcachments using a reducer. However, as soon as there are nested subcatchments, these catchment average values do not represent the full upstream area. It would be nice to support this option when defining output in the toml file.

For example: to get the full upstream average precipitation for catchment 201, would require catchments 209, 207, 203, and 206 to also be considered. Right now, the precipitation is only averaged over the area covered by catchment 201 (so the upstream areas are excluded)

Image

This is very useful in many applications, e.g. comparing average P, PET, AET, and Q for a given location.

Implementation Description

For example, this can be enabled using a flag in the .toml file

[[output.netcdf_scalar.variable]]
name = "P_Sall"
map = "sub_Sall"
parameter = "atmosphere_water__precipitation_volume_flux"
reducer = "mean"
entire_upstream = true

Additional Context

It would require creating a graph of the subcatchments to determine their dependencies, for which there is already functionality in Wflow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions