Skip to content
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

Update GSL on GitHub Actions CI #78

Merged
merged 6 commits into from
Nov 21, 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
22 changes: 12 additions & 10 deletions .github/workflows/ode-toolbox-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout ODE-toolbox code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.9

- name: Install apt dependencies
run: |
Expand Down Expand Up @@ -47,31 +47,33 @@ jobs:

steps:
- name: Checkout ODE-toolbox code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: 3.8
python-version: 3.9

- name: Install apt dependencies
run: |
sudo apt update
sudo apt install pkg-config python3-all-dev

- name: Install GSL
if: ${{ matrix.with_gsl == '1' }}
run: |
sudo apt remove libgsl27 libgsl-dev # remove system-wide GSL version that is installed by default
cd ..
wget http://ftp.wrz.de/pub/gnu/gsl/gsl-2.5.tar.gz
tar -xzf gsl-2.5.tar.gz
cd gsl-2.5
wget https://mirror.ibcp.fr/pub/gnu/gsl/gsl-2.7.tar.gz # this should be "gsl-latest.tar.gz", but there is an issue with GSL 2.8 (see https://github.com/pygsl/pygsl/issues/62)
tar -xzf gsl-2.7.tar.gz
cd gsl-2.7
./configure && make && sudo make install

- name: Install Python dependencies
run: |
python -m pip install --upgrade pip pytest pycodestyle codecov pytest-cov wheel
python -m pip install numpy
if [ "${{ matrix.with_gsl }}" == "1" ]; then python -m pip install pygsl ; fi
if [ "${{ matrix.with_gsl }}" == "1" ]; then python3 -m pip install -v https://github.com/pygsl/pygsl/archive/refs/tags/v2.4.1.tar.gz ; fi # this should be "pip install pygsl", but see https://github.com/pygsl/pygsl/issues/59
python -m pip install -r requirements.txt
export PYTHON_VERSION=`python -c "import sys; print('.'.join(map(str, [sys.version_info.major, sys.version_info.minor])))"`
echo "Python version detected:"
Expand Down
4 changes: 2 additions & 2 deletions doc/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ ODE-toolbox is written in Python and leverages SymPy for the symbolic manipulati
Installation
------------

.. Attention:: SymPy releases after 1.4 introduce a fourfold regression in runtime performance on the ODE-toolbox unit tests, compared to SymPy 1.4. Unless this conflicts with other version requirements, we would recommend to use SymPy 1.4 for now (for example, by editing ``requirements.txt`` to read ``sympy==1.4``).
.. Attention:: SymPy releases after 1.4 introduce a regression in runtime performance when computing matrix exponentials. Unless this conflicts with other version requirements, we recommend to use SymPy 1.4 for now (for example, by editing ``requirements.txt`` to read ``sympy==1.4``). This issue is being tracked at https://github.com/sympy/sympy/issues/23417.

.. Attention:: The latest SymPy release at time of writing, 1.10.1, introduces an issue that prevents ODE-toolbox from being used with many common neuron models. Please see https://github.com/sympy/sympy/issues/23417 and use an older SymPy version until this issue has been resolved.
.. Attention:: To perform solver benchmarking, ODE-toolbox relies on GSL and PyGSL. Currently, the latest PyGSL release is not compatible with GSL. We recommend to use GSL 2.7 for now. This issue is being tracked at https://github.com/pygsl/pygsl/issues/62.


Prerequisites
Expand Down