Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
dumux
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dumux-repositories
dumux
Commits
f47fb40a
Commit
f47fb40a
authored
2 years ago
by
Timo Koch
Browse files
Options
Downloads
Plain Diff
Merge branch 'fix/python-bindings' into 'master'
Fix python binding docs See merge request
!3366
parents
c42546ac
6f7e20d2
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!3366
Fix python binding docs
Pipeline
#26403
passed
2 years ago
Stage: check-status
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
python/README.md
+20
-14
20 additions, 14 deletions
python/README.md
with
20 additions
and
14 deletions
python/README.md
+
20
−
14
View file @
f47fb40a
...
...
@@ -23,14 +23,20 @@ this documentation in the future.
Checkout the
`master`
branch of the Dune core modules and DuMu
<sup>
x
</sup>
```
git clone https://gitlab.dune-project.org/core/dune-common
git clone https://gitlab.dune-project.org/core/dune-geometry
git clone https://gitlab.dune-project.org/core/dune-grid
git clone https://gitlab.dune-project.org/core/dune-localfunctions
git clone https://gitlab.dune-project.org/core/dune-istl
git clone https://git.iws.uni-stuttgart.de/dumux-repositories/dumux
git clone https://gitlab.dune-project.org/core/dune-common.git
git clone https://gitlab.dune-project.org/core/dune-geometry.git
git clone https://gitlab.dune-project.org/core/dune-grid.git
git clone https://gitlab.dune-project.org/core/dune-localfunctions.git
git clone https://gitlab.dune-project.org/core/dune-istl.git
git clone https://git.iws.uni-stuttgart.de/dumux-repositories/dumux.git
cp dumux/cmake.opts .
```
Enable shared libraries as required for the Python bindings by adding the flag in
`cmake.opts`
(see
comments inside the
`.opts`
file). Not setting this option is often responsible for error messages
related to parameters not being found.
Create and activate a new virtual environment in which the
Python modules will be installed in editable mode (symlinked)
...
...
@@ -54,12 +60,12 @@ this documentation in the future.
Checkout the
`releases/2.8`
branch of the Dune core modules and DuMu
<sup>
x
</sup>
3.5
```
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-common
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-geometry
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-grid
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-localfunctions
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-istl
git clone -b releases/3.5 https://git.iws.uni-stuttgart.de/dumux-repositories/dumux
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-common
.git
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-geometry
.git
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-grid
.git
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-localfunctions
.git
git clone -b releases/2.8 https://gitlab.dune-project.org/core/dune-istl
.git
git clone -b releases/3.5 https://git.iws.uni-stuttgart.de/dumux-repositories/dumux
.git
cp dumux/cmake.opts .
```
...
...
@@ -92,7 +98,7 @@ Replace the path with the path to the MPI library on your system.
Run your first DuMu
<sup>
x
</sup>
Python test
```
python3 dumux/test/python/test_
py_
gridgeometry.py
python3 dumux/test/python/test_gridgeometry.py
```
The Python bindings are based on just-in-time compilation of C++ code,
...
...
@@ -126,7 +132,7 @@ pylint build-cmake/python/dumux
```
Pylint needs to be able to check imports so the modules need to be properly set up
with
`setup-
dunepy.py`
(see above). The
`pylint`
configuration file
`dumux/.pylintrc`
can
with
`setup-
python-env.sh`
for Dune versions 2.8 or older
(see above). The
`pylint`
configuration file
`dumux/.pylintrc`
can
be used to configure
`pylint`
. Some exceptions or other parameters than the default
might be sensible in the future but generally advice given by
`pylint`
leads to better code.
Different from
`black`
,
`pylint`
does no itself fix the code, you need to do this yourself.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment