From 9a67a8a3058421a5148eb40c54dce80cc56daeda Mon Sep 17 00:00:00 2001 From: Henrique Musseli Cezar Date: Fri, 6 Oct 2023 09:08:51 +0200 Subject: [PATCH 1/2] Change pmesh requirement to enable upload to PyPI and update installation structures. --- .github/workflows/ci.yml | 1 + .github/workflows/docs_pages.yml | 1 + .github/workflows/release.yml | 1 + README.md | 2 ++ docs/doc_pages/installation.rst | 3 +++ requirements.txt | 2 +- 6 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ab85b747..b912af4a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,6 +41,7 @@ jobs: python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py + python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh python3 -m pip install -r requirements.txt - name: Install PLUMED run: | diff --git a/.github/workflows/docs_pages.yml b/.github/workflows/docs_pages.yml index 7eab21e2..f22fe798 100644 --- a/.github/workflows/docs_pages.yml +++ b/.github/workflows/docs_pages.yml @@ -32,6 +32,7 @@ jobs: run: | python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" + python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh python3 -m pip install -r requirements.txt - name: Install package run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 01314d06..7f48a4c4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,6 +22,7 @@ jobs: run: | python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" twine setuptools + python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh python3 -m pip install -r requirements.txt - name: Build and publish env: diff --git a/README.md b/README.md index a7a4fcb9..a60ce85a 100644 --- a/README.md +++ b/README.md @@ -46,8 +46,10 @@ CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py Install HyMD with `pip` by ```bash python3 -m pip install --upgrade numpy mpi4py cython +python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh python3 -m pip install hymd ``` +`pmesh` is installed from the GitHub repository because fixes to be compatible with modern NumPy versions were not pushed to PyPI. See [HyMD docs](https://cascella-group-uio.github.io/HyMD/doc_pages/installation.html) for more information, including install steps for macOS and non-Debian linux distributions. #### Run in docker diff --git a/docs/doc_pages/installation.rst b/docs/doc_pages/installation.rst index 930d5dbc..7dbca9a9 100644 --- a/docs/doc_pages/installation.rst +++ b/docs/doc_pages/installation.rst @@ -77,6 +77,7 @@ Dependencies python3 -m pip install --upgrade pip CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py python3 -m pip install mpi4py numpy cython + python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh .. group-tab:: Fedora (dnf) @@ -88,6 +89,7 @@ Dependencies python3.9 -m pip install mpi4py numpy cython export HDF5_DIR="/usr/lib64/openmpi/" CC="mpicc" HDF5_MPI="ON" python3.9 -m pip install --no-binary=h5py h5py + python3.9 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh .. group-tab:: Mac OSX (brew) @@ -112,6 +114,7 @@ Dependencies export HDF5_DIR="/usr/local/Cellar/hdf5-mpi/1.13.0/" CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py python3 -m pip install mpi4py numpy cython + python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh .. warning:: diff --git a/requirements.txt b/requirements.txt index 5ecd86be..83bf6598 100644 --- a/requirements.txt +++ b/requirements.txt @@ -7,4 +7,4 @@ tomli cython<3 mpsort pfft-python -pmesh @ git+https://github.com/rainwoodman/pmesh +pmesh From a2cade93dd24057f11f37f22002721abfdfab857 Mon Sep 17 00:00:00 2001 From: Henrique Musseli Cezar Date: Fri, 6 Oct 2023 09:13:26 +0200 Subject: [PATCH 2/2] Add quotes to pmesh installation --- .github/workflows/ci.yml | 2 +- .github/workflows/docs_pages.yml | 2 +- .github/workflows/release.yml | 2 +- README.md | 2 +- docs/doc_pages/installation.rst | 6 +++--- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b912af4a..5c7f8a6f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,7 +41,7 @@ jobs: python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py - python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" python3 -m pip install -r requirements.txt - name: Install PLUMED run: | diff --git a/.github/workflows/docs_pages.yml b/.github/workflows/docs_pages.yml index f22fe798..a7597486 100644 --- a/.github/workflows/docs_pages.yml +++ b/.github/workflows/docs_pages.yml @@ -32,7 +32,7 @@ jobs: run: | python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" - python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" python3 -m pip install -r requirements.txt - name: Install package run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7f48a4c4..39e2c303 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,7 +22,7 @@ jobs: run: | python3 -m pip install --upgrade pip python3 -m pip install --upgrade wheel numpy mpi4py "cython<3" twine setuptools - python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" python3 -m pip install -r requirements.txt - name: Build and publish env: diff --git a/README.md b/README.md index a60ce85a..b9ba5e24 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py Install HyMD with `pip` by ```bash python3 -m pip install --upgrade numpy mpi4py cython -python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh +python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" python3 -m pip install hymd ``` `pmesh` is installed from the GitHub repository because fixes to be compatible with modern NumPy versions were not pushed to PyPI. diff --git a/docs/doc_pages/installation.rst b/docs/doc_pages/installation.rst index 7dbca9a9..2f6e3659 100644 --- a/docs/doc_pages/installation.rst +++ b/docs/doc_pages/installation.rst @@ -77,7 +77,7 @@ Dependencies python3 -m pip install --upgrade pip CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py python3 -m pip install mpi4py numpy cython - python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" .. group-tab:: Fedora (dnf) @@ -89,7 +89,7 @@ Dependencies python3.9 -m pip install mpi4py numpy cython export HDF5_DIR="/usr/lib64/openmpi/" CC="mpicc" HDF5_MPI="ON" python3.9 -m pip install --no-binary=h5py h5py - python3.9 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3.9 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" .. group-tab:: Mac OSX (brew) @@ -114,7 +114,7 @@ Dependencies export HDF5_DIR="/usr/local/Cellar/hdf5-mpi/1.13.0/" CC="mpicc" HDF5_MPI="ON" python3 -m pip install --no-binary=h5py h5py python3 -m pip install mpi4py numpy cython - python3 -m pip install pmesh @ git+https://github.com/rainwoodman/pmesh + python3 -m pip install "pmesh @ git+https://github.com/rainwoodman/pmesh" .. warning::