5.13.3-dev0
mHM
The mesoscale Hydrological Model
Loading...
Searching...
No Matches
__init__.py
Go to the documentation of this file.
1"""!
2Python bindings of mHM.
3
4@copyright Copyright 2005-@today, the mHM Developers, Luis Samaniego, Sabine Attinger: All rights reserved.
5 mHM is released under the LGPLv3+ license @license_note
6"""
7
8##
9# @dir pybind
10# @brief @copybrief mhm
11# @details @copydetails mhm
12#
13# @dir mhm
14# @brief mhm Python package
15# @details @copydetails mhm
16#
17# @defgroup mhm mhm - Python bindings
18# @brief Python wrapper to control mHM.
19# @details The mhm python package provides a wrapper module to control mHM from Python.
20# This includes:
21# - initialization, running and finalizing a model run
22# - control of time stepping
23# - access to internal variables
24
25from . import cli, download
26from .cli import __version__
27from .download import download_test
28from .tools import (
29 get_mask,
30 get_parameter,
31 get_runoff,
32 get_runoff_eval,
33 get_variable,
34 set_meteo,
35)
36from .wrapper import get, model, run, set
37
38
39def __getattr__(name):
40 """Magic method to provide 'f_version' in Python."""
41 if name == "f_version":
42 return cli.f_version()
43 raise AttributeError(f"module {__name__} has no attribute {name}")
44
45
46__all__ = [
47 "cli",
48 "model",
49 "get",
50 "set",
51 "run",
52 "download",
53 "download_test",
54 "f_version",
55 "get_runoff",
56 "get_variable",
57 "get_runoff_eval",
58 "get_parameter",
59 "get_mask",
60 "set_meteo",
61 "__version__",
62]
__getattr__(name)
Magic method to provide 'f_version' in Python.
Definition __init__.py:39