Skip to content

Commit

Permalink
ENH: Bump scilpy to version 1.5.0 and upgrade dependencies
Browse files Browse the repository at this point in the history
Bump `scilpy` to version 1.5.0 and upgrade dependencies accordingly.

Require the `scilpy`-patched `dipy` version to avoid package
compatibility issues.

Remove the dependencies force-upgrade in the package testing workflow,
as the versions required by `scilpy` are now modern enough to avoid the
primary issues they intended to fix.

Fix the BLAS option warning in `numpy` triggered by `python-spams` when
using an earlier version of `numpy`. Fixes:
```
AttributeError: module 'numpy.__config__' has no attribute 'blas_opt_info'

ERROR: Failed building wheel for python-spams
```

reported in:
https://github.com/scil-vital/tractolearn/actions/runs/4901866945/jobs/8753373506#step:5:945
  • Loading branch information
jhlegarreta committed May 21, 2023
1 parent 9130346 commit 24971fa
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 32 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check_format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.8]
python-version: ['3.10']
requires: ['latest']

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/issue_title_labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.8'
python-version: '3.10'
- name: Install packages
run: |
python -m pip install --upgrade --user pip
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr_title_labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.8'
python-version: '3.10'
- name: Install packages
run: |
python -m pip install --upgrade --user pip
Expand Down
12 changes: 1 addition & 11 deletions .github/workflows/test_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
# max-parallel: 6
matrix:
os: [ubuntu-latest]
python-version: [3.8]
python-version: ['3.10']
requires: ['minimal', 'latest']

steps:
Expand Down Expand Up @@ -53,16 +53,6 @@ jobs:
python -m pip install --upgrade --user pip
pip install setuptools tox
pip install -e .[test]
# Force upgrading packages to workaround the `scilpy` requested versions
pip install --upgrade matplotlib==3.1.0
pip install --upgrade numpy==1.23.0
# Force upgrading packages to avoid numpy-related built-in type deprecation warnings
pip install --upgrade dipy==1.4.1
pip install --upgrade fury==0.7.1
pip install --upgrade h5py==3.0.0
pip install --upgrade nibabel==3.2.1
pip install --upgrade scikit-learn==0.24.0
pip install --upgrade scipy==1.7.0
python --version
pip --version
pip list
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
default_language_version:
python: python3.8
python: python3.10

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ Tractography learning.
## Installation

To use tractolearn, it is recommended to create a virtual environment using
python 3.8 that will host the necessary dependencies. Torch tested with an
python 3.10 that will host the necessary dependencies. Torch tested with an
NVIDIA RTX 3090 with:

```sh
virtualenv tractolearn_env --python=python3.8
virtualenv tractolearn_env --python=python3.10
source tractolearn_env/bin/activate
```

Expand Down
28 changes: 14 additions & 14 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,25 @@ dependencies = [
# common dependencies
"importlib-metadata",
"comet-ml == 3.0.0",
"h5py == 2.10.0",
"matplotlib >= 2.2.0",
"numpy >= 1.20.0",
"h5py == 3.7.0",
"matplotlib == 3.6.0",
"numpy == 1.23.0",
"pandas",
"pathos",
"pyyaml",
"seaborn == 0.11.0",
"scikit-learn == 0.22.0",
"scipy == 1.4.0",
"torch == 1.8.1",
"scikit-learn == 1.2.0",
"scipy == 1.9.0",
"torch == 1.13.0",
"torchsummary == 1.5.1",
"tqdm",
"umap-learn",
# DWI dependencies
"dipy == 1.3.0",
"fury == 0.7.1",
"nibabel == 3.0.0",
"dipy @ git+https://github.com/scilus/[email protected]#egg=dipy",
"fury == 0.8.0",
"nibabel == 4.0.0",
# Git dependencies
"scilpy @ git+https://github.com/scilus/scilpy@1.2.2",
"scilpy @ git+https://github.com/scilus/scilpy@1.5.0",
]
description = "Tractography learning"
dynamic = ["version"]
Expand All @@ -48,16 +48,16 @@ maintainers = [
]
name = "tractolearn"
readme = "README.md"
requires-python = ">=3.8"
requires-python = ">=3.10"

[project.optional-dependencies]
test = [
"hypothesis >= 6.8.0",
"pytest == 5.3",
"pytest == 7.2.0",
"pytest-cov",
"pytest-pep8",
"pytest-xdist",
"pytest_console_scripts",
"pytest_console_scripts == 1.3.0",
]
dev = [
"black == 22.12",
Expand Down Expand Up @@ -86,7 +86,7 @@ repository = "https://github.com/scil-vital/tractolearn"

[tool.black]
line-length = 79
target-version = ["py38"]
target-version = ["py310"]
exclude ='''
(
/(
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py38
envlist = py310
isolated_build = True

[testenv]
Expand Down

0 comments on commit 24971fa

Please sign in to comment.