Skip to content

Commit

Permalink
Merge branch 'main' into bugfixes-maps
Browse files Browse the repository at this point in the history
  • Loading branch information
shartgring authored Nov 25, 2024
2 parents 031df0c + 6956f9e commit 6c40bc1
Show file tree
Hide file tree
Showing 13 changed files with 345 additions and 28 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,9 @@ target/

# Jupyter Notebook
.ipynb_checkpoints
.examples/build
examples/build
examples/data/*
!examples/data/refine.geojson

# IPython
profile_default/
Expand Down
1 change: 1 addition & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ UNRELEASED

Added
-----
- Included new example notebook for basic HydroMT use through CLI. (PR #202)

Changed
-------
Expand Down
1 change: 1 addition & 0 deletions docs/dev_guide/contributors.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ Contributors
* Hélène Boisgontier `@hboisgon <https://github.com/hboisgon>`_
* Rinske Hutten `@rhutten <https://github.com/rhutten>`_
* Arthur van Dam `https://github.com/arthurvd`_
* Sebastian Hartgring `https://github.com/shartgring`_
14 changes: 9 additions & 5 deletions docs/getting_started/example_index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,20 @@ List of examples

For a static (non-interactive) view of the examples follow one of the links below:

**Introduction to HydroMT Delft3D FM**

* `HydroMT tutorial <../_examples/hydromt_tutorial.ipynb>`_

**Build model from command line interface**

* `Build Delft3DFM 1D model <../_examples/build_1dmodel.ipynb>`_
* `Build Delft3DFM 2D model <../_examples/build_2dmodel.ipynb>`_
* `Build Delft3DFM 1D2D model <../_examples/build_1d2dmodel.ipynb>`_
* `Build Delft3D FM 1D model <../_examples/build_1dmodel.ipynb>`_
* `Build Delft3D FM 2D model <../_examples/build_2dmodel.ipynb>`_
* `Build Delft3D FM 1D2D model <../_examples/build_1d2dmodel.ipynb>`_

**Update model from command line interface**

* `Update Delft3DFM model: refine 2dgrid <../_examples/update_refine_2dgrid.ipynb>`_
* `Update Delft3D FM model: refine 2dgrid <../_examples/update_refine_2dgrid.ipynb>`_

**Postprocessing and visualization**

* `Plot Delft3DFM model <../_examples/plot_dflowfm_mesh.ipynb>`_
* `Plot Delft3D FM model <../_examples/plot_dflowfm_mesh.ipynb>`_
2 changes: 1 addition & 1 deletion docs/getting_started/faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Frequently asked questions
==========================

This page contains some FAQ / tips and tricks to work with HydroMT-Delft3DFM.
This page contains some FAQ / tips and tricks to work with HydroMT Delft3D FM.
For more general questions on how to work with data or the HydroMT config and command line,
you can visit the `HydroMT core FAQ page <https://deltares.github.io/hydromt/latest/getting_started/faq.html>`_

Expand Down
12 changes: 6 additions & 6 deletions docs/getting_started/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ For more information about the prerequisites for an installation of the HydroMT
and related dependencies, please visit the documentation of
`HydroMT core <https://deltares.github.io/hydromt/latest/getting_started/installation.html#installation-guide>`_

Compared to HydroMT, HydroMT-delft3dfm has additional dependencies, namely:
Compared to HydroMT, HydroMT Delft3D FM has additional dependencies, namely:

- `xugrid <https://github.com/Deltares/xugrid>`_
- `hydrolib-core <https://github.com/Deltares/HYDROLIB-core>`_
Expand All @@ -20,13 +20,13 @@ Compared to HydroMT, HydroMT-delft3dfm has additional dependencies, namely:
Installation
============

HydroMT-Delft3DFM is available on pypi.
HydroMT Delft3D FM is available on pypi.

Install HydroMT-Delft3DFM in a new environment
Install HydroMT Delft3D FM in a new environment
----------------------------------------------

You can install HydroMT-Delft3DFM in a new environment (recommended!) called `hydromt-delft3dfm`.
HydroMT-Delft3DFM is available on pypi but not yet available on conda-forge.
You can install HydroMT Delft3D FM in a new environment (recommended!) called `hydromt-delft3dfm`.
HydroMT Delft3D FM is available on pypi but not yet available on conda-forge.
Therefore, we recommend creating a conda environment and install everything with pip.

.. code-block:: console
Expand All @@ -39,7 +39,7 @@ Then, activate the environment:
$ conda activate hydromt-delft3dfm
Finally, install Hydromt-Delft3DFM from pypi using pip.
Finally, install HydroMT Delft3D FM from pypi using pip.

.. code-block:: console
Expand Down
7 changes: 4 additions & 3 deletions docs/user_guide/dflowfm_build.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ data libraries are set, you can build a model by using:

Configuration file
------------------
Settings to build or update a Delft3DFM model are managed in a configuration file. In this file,
Settings to build or update a Delft3D FM model are managed in a configuration file. In this file,
every option from each :ref:`model method <model_methods>` can be changed by the user
in its corresponding section.

Expand All @@ -26,7 +26,7 @@ Note that the order in which the components are listed in the yml file is import
- When setting up a 1D2D model, both of the above should be run first, before calling `setup_link1d2d`.


Below is an example yml file that can be used to build a complete Delft3DFM model
Below is an example yml file that can be used to build a complete Delft3D FM model
:download:`.yml file <../_examples/delft3dfm_build.yml>`. Each section corresponds
to a model component with the same name.

Expand All @@ -53,4 +53,5 @@ are three ways for the user to select which data libraries to use:
.. toctree::
:hidden:

Example: Build Delft3DFM 1D2D model <../_examples/build_1d2dmodel.ipynb>
Example: Introduction to HydroMT Delft3D FM <../_examples/hydromt_tutorial.ipynb>
Example: Build Delft3D FM 1D2D model <../_examples/build_1d2dmodel.ipynb>
4 changes: 2 additions & 2 deletions docs/user_guide/dflowfm_update.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Updating a model
----------------
To add or change one or more components of an existing Delft3DFM model the ``update`` method can be used.
To add or change one or more components of an existing Delft3D FM model the ``update`` method can be used.

**Steps in brief:**

Expand Down Expand Up @@ -33,4 +33,4 @@ To add or change one or more components of an existing Delft3DFM model the ``upd
.. toctree::
:hidden:

Example: Update Delft3DFM model (refine 2dgrid) <../_examples/update_refine_2dgrid.ipynb>
Example: Update Delft3D FM model (refine 2dgrid) <../_examples/update_refine_2dgrid.ipynb>
6 changes: 3 additions & 3 deletions docs/user_guide/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
User guide
==========

With the **Hydromt-Delft3DFM plugin**, users can easily benefit from the rich set of tools of the
With the **HydroMT Delft3D FM plugin**, users can easily benefit from the rich set of tools of the
`HydroMT package <https://deltares.github.io/hydromt/latest/index.html>`_ to build and update
`Delft3D FM Suite <https://www.deltares.nl/en/software-and-data/products/sobek-and-delft3d-fm-suite-1d2d>`_ models from available global and local data.

This plugin assists the Delft3D FM modeller in:

- Quickly setting up a base Delft3dFM model (1D2D) and default parameter values
- Quickly setting up a base Delft3D FM model (1D2D) and default parameter values
- Making maximum use of the best available global or local data
- Adjusting and updating components of a Delft3dFM model and their associated data in a consistent way
- Adjusting and updating components of a Delft3D FM model and their associated data in a consistent way

Two Delft3dFM Model classes are currently available:

Expand Down
8 changes: 4 additions & 4 deletions examples/build_1d2dmodel.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
"outputs": [],
"source": [
"# NOTE: copy this line (without !) to your shell for more direct feedback - should take about 1 minute or 2 to run\n",
"!hydromt build dflowfm \"./build/dflowfm_1d2d\" -i dflowfm_build.yml -d artifact_data --fo -vv"
"!hydromt build dflowfm \"./build/dflowfm_1d2d\" -i dflowfm_build_piave.yml -d artifact_data --fo -vv"
]
},
{
Expand All @@ -200,7 +200,7 @@
"\n",
"* `dflowfm` : i.e. build a FM model\n",
"* `./build/dflowfm_1d2d` : output model folder\n",
"* `-i dflowfm_build.yml`: model build configuration file\n",
"* `-i dflowfm_build_piave.yml`: model build configuration file\n",
"* `-d artifact_data`: data catalog to use. Here the default artifact data catalog with global data for Northern Italy.\n",
"* `--fo`: force overwritting in case a model already exists in the output folder.\n",
"* `-vv` : give some extra verbosity (2 * v) to display feedback on screen. Now debug and info messages are provided rather than only warnings and errors.\n",
Expand Down Expand Up @@ -267,7 +267,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "waterbom",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
Expand All @@ -281,7 +281,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.0"
"version": "3.9.20"
},
"vscode": {
"interpreter": {
Expand Down
4 changes: 2 additions & 2 deletions examples/build_1dmodel.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "waterbom",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
Expand All @@ -269,7 +269,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.18"
"version": "3.9.20"
},
"vscode": {
"interpreter": {
Expand Down
Loading

0 comments on commit 6c40bc1

Please sign in to comment.