hydromt.LumpedModel#

class hydromt.LumpedModel(root: ~typing.Optional[str] = None, mode: str = 'w', config_fn: ~typing.Optional[str] = None, data_libs: ~typing.Optional[~typing.List[str]] = None, logger=<Logger hydromt.models.model_lumped (WARNING)>)[source]#

Model class Lumped Model for lumped models in HydroMT

Initialize a LumpedModel for lumped and semi-distributed models.

__init__(root: ~typing.Optional[str] = None, mode: str = 'w', config_fn: ~typing.Optional[str] = None, data_libs: ~typing.Optional[~typing.List[str]] = None, logger=<Logger hydromt.models.model_lumped (WARNING)>)[source]#

Initialize a LumpedModel for lumped and semi-distributed models.

Methods

__init__([root, mode, config_fn, data_libs, ...])

Initialize a LumpedModel for lumped and semi-distributed models.

build(region[, res, write, opt])

Single method to build a model from scratch based on settings in opt.

get_config(*args[, fallback, abs_path])

Get a config value at key(s).

read([components])

Read the complete model schematization and configuration from model files.

read_config([config_fn])

Parse config from file.

read_forcing([fn])

Read forcing at <root>/<fn> and add to forcing property

read_geoms([fn])

Read model geometries files at <root>/<fn> and add to geoms property

read_maps([fn])

Read model map at <root>/<fn> and add to maps component

read_response_units([fn, fn_geom])

Read model response units from combined netcdf file at <root>/<fn> and geojson file at <root>/<fn_geom>.

read_results([fn])

Read results at <root>/<fn> and add to results property

read_states([fn])

Read states at <root>/<fn> and add to states property

read_staticgeoms()

This method will be deprecated in future versions, use read_geoms()

read_staticmaps([fn])

Read static model maps at <root>/<fn> and add to staticmaps property

set_config(*args)

Update the config dictionary at key(s) with values.

set_crs(crs)

set_forcing(data[, name, split_dataset])

Add data to forcing attribute.

set_geoms(geom, name)

Add data to the geoms attribute.

set_maps(data[, name, split_dataset])

Add raster data to the maps component.

set_response_units(data[, name])

Add data to response_units.

set_results(data[, name, split_dataset])

Add data to results attribute.

set_root(root[, mode])

Initialize the model root.

set_states(data[, name, split_dataset])

Add data to states attribute.

set_staticgeoms(geom, name)

This method will be deprecated in future versions, use set_geoms()

set_staticmaps(data[, name])

This method will be deprecated in future versions.

setup_basemaps(*args, **kwargs)

setup_config(**cfdict)

Update config with a dictionary

setup_maps_from_raster(raster_fn[, ...])

This component adds data variable(s) from raster_fn to maps object.

setup_maps_from_raster_reclass(raster_fn, ...)

This component adds data variable(s) to maps object by reclassifying the data in raster_fn based on reclass_table_fn.

setup_region(region[, hydrography_fn, ...])

This component sets the region of interest of the model.

test_model_api()

update([model_out, write, opt])

Single method to update a model based the settings in opt.

write([components])

Write the complete model schematization and configuration to model files.

write_config([config_name, config_root])

Write config to <root/config_fn>

write_data_catalog([root, used_only])

Write the data catalog to hydromt_data.yml

write_forcing([fn])

Write forcing to netcdf file at <root>/<fn>

write_geoms([fn])

Write model geometries to a vector file (by default GeoJSON) at <root>/<fn>

write_maps([fn])

Write maps to netcdf file at <root>/<fn>

write_response_units([fn, fn_geom])

Write model response units to combined netcdf file at <root>/<fn> and geojson file at <root>/<fn_geom>.

write_states([fn])

Write states to netcdf file at <root>/<fn>

write_staticgeoms()

This method will be deprecated in future versions, use write_geoms()

write_staticmaps([fn])

Write static model maps to netcdf file at <root>/<fn>

Attributes

api

Return all model components and their data types

bounds

Returns the bounding box of the model region.

config

Model configuration.

coords

Returns the coordinates of model staticmaps.

crs

Returns coordinate reference system embedded in region.

dims

Returns spatial dimension names of staticmaps.

forcing

Model forcing.

geoms

Model geometries.

height

Returns the height of the model staticmaps.

maps

Model maps.

region

Returns the geometry of the model area of interest.

res

Returns the resolution of the model staticmaps.

response_units

Model response unit (lumped) data.

results

Model results.

root

Path to model folder.

shape

Returns the shape of the model staticmaps.

states

Model states.

staticgeoms

This property will be deprecated in future versions, use geom()

staticmaps

Model static maps.

transform

Returns the geospatial transform of the model staticmaps.

width

Returns the width of the model staticmaps.