-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from KrisThielemans/docPip
Update to PETSIRD v0.2.0 and adapt Python documentation
- Loading branch information
Showing
4 changed files
with
9 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,6 +50,7 @@ jobs: | |
- name: Python | ||
run: | | ||
pip install ./PETSIRD/python | ||
cd python | ||
python start.py | ||
|
Submodule PETSIRD
updated
6 files
+1 −1 | .github/workflows/ci.yml | |
+2 −0 | .gitignore | |
+9 −3 | README.md | |
+26 −1 | python/README.md | |
+10 −0 | python/README.pypi.md | |
+4 −2 | python/pyproject.toml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
# PETSIRD basic Python example | ||
|
||
This directory contains some instructions to wrote Python code to read/write PETSIRD data. You need to `yardl generate` in the `model` directory first. | ||
As you can now install the `petsird` package from PyPI, you likely no longer | ||
need this repository and can just use `pip install petsird`. | ||
You can of course use the Python package generated from the local PETSIRD | ||
clone (`cd python; pip install .`). See | ||
https://github.com/ETSInitiative/PETSIRD/tree/main/python#readme | ||
for more information. | ||
|
||
As we currently do not have a `set_up.py` for PETSIRD yet, the example file hard-codes the path to the generated files. | ||
Alternatives would be to use the `PYTHONPATH` environment variable or symbolic links. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import sys | ||
# Currently hard-wire location of generated files. This will need to change! | ||
sys.path.append('../PETSIRD/python/') | ||
import petsird | ||
help(petsird.BinaryPETSIRDReader) | ||
|