Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Issue #793 Fix errors and warnings during the creation of the documentation #794

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions docs/api/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Fixed
- Fixed bugs with clipping :class:`imod.mf6.HorizontalFlowBarrier` for
structured grids
- Improved performance for merging structured multimodel Modflow 6 output
- Bug where :function:`imod.formats.idf.open_subdomains` did not properly support custom
- Bug where :func:`imod.formats.idf.open_subdomains` did not properly support custom
patterns

Changed
Expand Down Expand Up @@ -47,7 +47,7 @@ Fixed
- Fixed bug where simulations with :class:`imod.mf6.Well` were not partitioned
into multiple models.
- Fixed erroneous default value for the ``out_of_bounds`` in
:function:`imod.select.points.point_values`
:func:`imod.select.points.point_values`
- Fixed bug where :class:`imod.mf6.Well` could not be assigned to the first cell
of an unstructured grid.
- HorizontalFlowBarrier package now dropped if completely outside partition in a
Expand Down Expand Up @@ -88,8 +88,8 @@ Fixed
default tile provider being used was Stamen. However Stamen is no longer free
which caused Contextily to fail. The default tile provider has been changed to
OpenStreetMap to resolve this issue.
- :function:`imod.mf6.open_cbc` now reads saved cell saturations and specific discharges.
- :function:`imod.mf6.open_cbc` failed to read unstructured budgets stored
- :func:`imod.mf6.open_cbc` now reads saved cell saturations and specific discharges.
- :func:`imod.mf6.open_cbc` failed to read unstructured budgets stored
following IMETH1, most importantly the storage fluxes.
- Fixed support of Python 3.11 by dropping the obsolete ``qgs`` module.
- Bug in :class:`imod.mf6.SourceSinkMixing` where, in case of multiple active
Expand Down Expand Up @@ -121,11 +121,11 @@ Added
- The unit tests results are now published on GitLab
- A ``save_saturation`` option to :class:`imod.mf6.NodePropertyFlow` which saves
cell saturations for unconfined flow.
- Functions :function:`imod.prepare.layer.get_upper_active_layer_number` and
:function:`imod.prepare.layer.get_lower_active_layer_number` to return planar
- Functions :func:`imod.prepare.layer.get_upper_active_layer_number` and
:func:`imod.prepare.layer.get_lower_active_layer_number` to return planar
grids with numbers of the highest and lowest active cells respectively.
- Functions :function:`imod.prepare.layer.get_upper_active_grid_cells` and
:function:`imod.prepare.layer.get_lower_active_grid_cells` to return boolean
- Functions :func:`imod.prepare.layer.get_upper_active_grid_cells` and
:func:`imod.prepare.layer.get_lower_active_grid_cells` to return boolean
grids designating respectively the highest and lowest active cells in a grid.
- validation of ``transient`` argument in :class:`imod.mf6.StorageCoefficient`
and :class:`imod.mf6.SpecificStorage`.
Expand All @@ -142,7 +142,7 @@ Added
connect the submodels. At the moment auxiliary variables ``cdist`` and
``angldegx`` are only computed for structured grids.
- The label array can be generated through a convenience function
:function:`imod.mf6.partition_generator.get_label_array`
:func:`imod.mf6.partition_generator.get_label_array`
- Once a split simulation has been executed by MF6, we find head and balance
results in each of the partition models. These can now be merged into head and
balance datasets for the original domain using
Expand Down
3 changes: 0 additions & 3 deletions docs/api/metamod.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,3 @@ MetaMod
:toctree: generated/metamod

MetaMod
NodeSvatMapping
RechargeSvatMapping
WellSvatMapping
8 changes: 4 additions & 4 deletions docs/api/prepare.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Prepare model input

assign_wells

get_lower_active_grid_cells,
get_lower_active_layer_number,
get_upper_active_grid_cells,
get_upper_active_layer_number,
get_lower_active_grid_cells
get_lower_active_layer_number
get_upper_active_grid_cells
get_upper_active_layer_number
42 changes: 13 additions & 29 deletions docs/faq/python.rst
Original file line number Diff line number Diff line change
Expand Up @@ -144,45 +144,29 @@ Setting up an environment
At some point you will run into a dependency issue. Sometimes the dependency
requirements of two packages are straight out unsatisfiable. In other cases,
you'd like to use the latest version, but this would break other packages.
The solution conda offers is easy switching between different Python
installations. A conda environment is simply a complete Python installation
with all necessary dependencies. Creating a new environment will result in a
new Python installation, without sharing of dependencies with other
The solution used by imod-python is using Pixi. Pixi creates a complete Python
installation with all necessary dependencies. Creating a new environment will
result in a new Python installation, without sharing of dependencies with other
environments. (This is hardly the most efficient use of your hard disk space
from a theoretical perspective, but it greatly simplifies matters in the
practical sense.)

Below is the specification for an environment that should provide you with
all the dependencies and requirements you need to build groundwater models
with iMOD Python, and then some (for testing/development).
To create a Pixi environment open a command prompt and ``cd`` to the imod folder.
In the imod folder use the following command::

.. literalinclude:: ../../imod-environment.yml
:language: yaml
:caption: imod-environment.yml
pixi run install

Save this text into a file called ``imod-environment.yml``, location doesn't
really matter. In your command prompt, ``cd`` to this location and run::
This will create a conda environment inside the imod folder. To activate the environment run::

mamba env create -f imod-environment.yml
pixi shell

This will create a conda environment named ``imod`` as it is specified in the
file.

Environments can be "activated" by running::

conda activate {name of environment}

Active the just installed environment by running::

conda activate imod

This essentially temporarily updates your `PATH variable`_, which is the set
of directories where executable programs are located. After deactivating the
conda environment, either via ``conda deactivate`` or by closing the command
prompt, these directories are removed from PATH again so that the Python
installation is properly isolated.
of directories where executable programs are located. closing the command prompt,
these directories are removed from PATH again so that the Python installation is
properly isolated.

Read more at the full `conda docs`_.
Read more at the full `pixi docs`_.


Installing a newer or old version
Expand Down Expand Up @@ -219,5 +203,5 @@ Past versions can also be found on the iMOD Python `releases page`_.
.. _Terms of Service: https://www.anaconda.com/terms-of-service
.. _conda-forge: https://conda-forge.org/
.. _PATH variable: https://en.wikipedia.org/wiki/PATH_(variable)
.. _conda docs: https://conda.io/projects/conda/en/latest
.. _pixi docs: https://pixi.sh/
.. _releases page: https://github.com/Deltares/imod-python/releases
File renamed without changes.
3 changes: 3 additions & 0 deletions examples/mf6/circle_partitioned.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
"""
Circle partitioned
==================

This example illustrates a circular model that is split into 3 submodels.
The split method returns a simulation object that can be run as is. In this
case the 3 submodels are roughly equal sized partitions that have the shape
Expand Down