From ccffbdd53b3c4f656447543d76a8106d81ae48e0 Mon Sep 17 00:00:00 2001 From: Antoine Wehenkel Date: Tue, 14 Feb 2023 14:52:07 +0100 Subject: [PATCH] Correct package requirements for tests. (#271) * Test commit on personal fork. * Test commit on personal fork. * Add and update copyrights. * Correct packages requirements for tests. * Add apt-get install libsuitesparse-dev to get tests with scikit-sparse running on github. * Corect os runner check and also add it to "norma" tests. * Add brew install for scikit sparse. * remove scikit-sparse from 3.11. * Install libsuite sparse for gpu env tests. * Remove libsuite sparse for gpu env tests (added in the docker). --------- Co-authored-by: antoinewehenkel --- .github/workflows/tests.yml | 21 +++++++++++++++++++++ pyproject.toml | 4 +--- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index dcbccf36d..885f5e719 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -23,6 +23,16 @@ jobs: with: python-version: '3.9' + - name: Install apt dependencies + if: ${{ runner.os == 'Linux' }} + run: | + sudo apt-get install libsuitesparse-dev + + - name: Install brew dependencies + if: ${{ runner.os == 'macOS' }} + run: | + brew install suite-sparse + - name: Install dependencies run: | python -m pip install --upgrade pip @@ -44,6 +54,7 @@ jobs: options: --gpus="device=12" steps: - uses: actions/checkout@v3 + - name: Install dependencies # `jax[cuda]<0.4` because of Docker issues: https://github.com/google/jax/issues/13758 # `flax<0.6.5` because it requires `jax>=0.4.2` @@ -80,6 +91,16 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Install apt dependencies + if: ${{ runner.os == 'Linux' }} + run: | + sudo apt-get install libsuitesparse-dev + + - name: Install brew dependencies + if: ${{ runner.os == 'macOS' }} + run: | + brew install suite-sparse + - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/pyproject.toml b/pyproject.toml index 004edfdb3..584a30818 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,9 +74,6 @@ test = [ "networkx>=2.5", "scikit-learn>=1.0" ] -experimental = [ - "scikit-sparse>=0.4.6", -] docs = [ "sphinx>=4.0", "ipython>=7.20.0", @@ -177,6 +174,7 @@ legacy_tox_ini = """ [testenv] extras = test pass_env = CUDA_*,PYTEST_*,CI + deps = py{38,39,310}: scikit-sparse>=0.4.6 commands = gpu: pip install "jax[cuda]" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html python -m pytest {tty:--color=yes} {posargs: \