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

Test against numpy 2.0 #1140

Open
wants to merge 36 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
5277cb0
Test with python 3.12
arokem Jul 22, 2024
d17f9ec
Merge branch 'master' of github.com:yeatmanlab/pyAFQ
arokem Aug 15, 2024
5ebff32
Merge branch 'master' of github.com:yeatmanlab/pyAFQ
arokem Aug 31, 2024
7a73a78
Merge branch 'master' of github.com:yeatmanlab/pyAFQ
arokem Oct 4, 2024
af62e99
User newer python for releases.
arokem Oct 8, 2024
7c52209
Back off upgrade to python 3.12
arokem Oct 8, 2024
fd0ca15
Update upload artifact.
arokem Oct 8, 2024
477d860
Adapt the release workflow.
arokem Oct 8, 2024
90eed2a
Use the new repo to clone from.
arokem Oct 9, 2024
57cea56
Run docbuild only on one version of Python.
arokem Oct 9, 2024
3d3fb0f
Point docker build to this repo instead of yeatmanlab.
arokem Oct 9, 2024
d4f977b
Merge pull request #1 from tractometry/new_release
arokem Oct 9, 2024
4512e84
Replace yeatmanlab with tractometry wherever that appears.
arokem Oct 9, 2024
b753c9b
Update .zenodo.json
arokem Oct 9, 2024
ab231ec
Update AFQ/tasks/viz.py
arokem Oct 9, 2024
4c9e26e
Update README.md
arokem Oct 9, 2024
a3e6ea3
These should still point to yeatmanlab
arokem Oct 9, 2024
526be1d
Update bin/pyAFQ
arokem Oct 9, 2024
4380be0
Update bin/pyAFQ
arokem Oct 9, 2024
88b55c0
Update docs/source/explanations/modeling.rst
arokem Oct 9, 2024
94ac5c3
Update docs/source/howto/developing/index.rst
arokem Oct 9, 2024
9fc1536
Update docs/source/howto/developing/index.rst
arokem Oct 9, 2024
969cf4c
Update docs/source/howto/usage/kwargs.rst
arokem Oct 9, 2024
5d96789
Update examples/tutorial_examples/plot_002_bids_layout.py
arokem Oct 9, 2024
f573988
Update examples/howto_examples/cloudknot_hcp_example.py
arokem Oct 9, 2024
ff2a920
Update docs/source/reference/kwargs.rst
arokem Oct 9, 2024
f9ef051
Update docs/source/howto/usage/kwargs.rst
arokem Oct 9, 2024
9e4648b
Update examples/howto_examples/cloudknot_hcp_example.py
arokem Oct 9, 2024
59c2fc2
Update workflows, including concurrency.
arokem Oct 9, 2024
67915ac
Merge branch 'no_yeatmanlab' of github.com:tractometry/pyAFQ into no_…
arokem Oct 9, 2024
3bf0941
Merge pull request #2 from tractometry/no_yeatmanlab
arokem Oct 10, 2024
ef68765
Only upload the docs in one of the Python versions.
arokem Oct 4, 2024
24aa128
Test against the numpy 2.0 release candidate.
arokem May 23, 2024
0da53a6
Bump to numpy 2.1.0.
arokem Oct 5, 2024
82e4d17
Use newer versions of Python everywhere.
arokem Oct 5, 2024
9e02399
Upgrade DIPY to a version that works with numpy 2.
arokem Oct 5, 2024
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
30 changes: 15 additions & 15 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,19 +94,19 @@ is difficult to be described as one unit of work, please consider splitting it i

The current list of issue labels are [here][link_labels] and include:

* [![Good first issue](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/good%20first%20issue)][link_firstissue] *These issues contain a task that is amenable to new contributors because it doesn't entail a steep learning curve.*
* [![Good first issue](https://img.shields.io/github/labels/tractometry/pyAFQ/good%20first%20issue)][link_firstissue] *These issues contain a task that is amenable to new contributors because it doesn't entail a steep learning curve.*

If you feel that you can contribute to one of these issues,
we especially encourage you to do so!

* [![Bug](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/bug)][link_bugs] *These issues point to problems in the project.*
* [![Bug](https://img.shields.io/github/labels/tractometry/pyAFQ/bug)][link_bugs] *These issues point to problems in the project.*

If you find new a bug, please give as much detail as possible in your issue,
including steps to recreate the error.
If you experience the same bug as one already listed,
please add any additional information that you have as a comment.

* [![Enhancement](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/enhancement)][link_enhancement] *These issues are asking for new features and improvements to be considered by the project.*
* [![Enhancement](https://img.shields.io/github/labels/tractometry/pyAFQ/enhancement)][link_enhancement] *These issues are asking for new features and improvements to be considered by the project.*

Please try to make sure that your requested feature is distinct from any others
that have already been requested or implemented.
Expand All @@ -118,16 +118,16 @@ we have two sets of special labels:

| Label | Description |
|--------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------|
| ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20high) <br> ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20medium) <br> ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20low) | Estimation of the downstream impact the proposed feature/bugfix will have. |
| ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20high) <br> ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20medium) <br> ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20low) | Estimation of effort required to implement the requested feature or fix the reported bug. |
| ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20high) <br> ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20medium) <br> ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20low) | Estimation of the downstream impact the proposed feature/bugfix will have. |
| ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20high) <br> ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20medium) <br> ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20low) | Estimation of effort required to implement the requested feature or fix the reported bug. |

These labels help triage and set priorities to the development tasks.
For instance, one bug regression that has been reported to affect most of the users after
a release with an easy fix because it is a known old problem that came back.
Such an issue will typically be assigned the following labels ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/bug) ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20high) ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20low), and its priority will be maximal since addressing low-effort high-impact deliver the maximum turnout without increasing the churn by much.
Such an issue will typically be assigned the following labels ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/bug) ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20high) ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20low), and its priority will be maximal since addressing low-effort high-impact deliver the maximum turnout without increasing the churn by much.

Of course, the implementation of long-term goaled lines may include the scheduling of ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20medium) ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20high).
Finally, ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/impact%3A%20low) ![GitHub labels](https://img.shields.io/github/labels/yeatmanlab/pyAFQ/effort%3A%20high) issues are less likely to be addressed.
Of course, the implementation of long-term goaled lines may include the scheduling of ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20medium) ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20high).
Finally, ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/impact%3A%20low) ![GitHub labels](https://img.shields.io/github/labels/tractometry/pyAFQ/effort%3A%20high) issues are less likely to be addressed.

## Making a change

Expand Down Expand Up @@ -156,7 +156,7 @@ but those accepted fastest will follow a workflow similar to the following:
add the ["upstream" pyAFQ repository as a remote][link_addremote]
to your locally cloned repository.
```Shell
git remote add upstream https://github.com/yeatmanlab/pyAFQ.git
git remote add upstream https://github.com/tractometry/pyAFQ.git
```
Make sure to [keep your fork up to date][link_updateupstreamwiki] with the upstream repository.<br />
For example, to update your master branch on your local cloned repository:
Expand Down Expand Up @@ -240,7 +240,7 @@ acknowledge that any contributions will be licensed under the same terms.
[MetPy project](https://github.com/Unidata/MetPy).

[link_github]: https://github.com/
[link_pyAFQ]: https://github.com/yeatmanlab/pyAFQ
[link_pyAFQ]: https://github.com/tractometry/pyAFQ
[link_signupinstructions]: https://help.github.com/articles/signing-up-for-a-new-github-account

[link_neurostars]: https://neurostars.org/tags/pyAFQ
Expand All @@ -254,13 +254,13 @@ acknowledge that any contributions will be licensed under the same terms.
[rick_roll]: https://www.youtube.com/watch?v=dQw4w9WgXcQ

[autofq]: https://autofq.org/
[link_issues]: https://github.com/yeatmanlab/pyAFQ/issues
[link_labels]: https://github.com/yeatmanlab/pyAFQ/labels
[link_issues]: https://github.com/tractometry/pyAFQ/issues
[link_labels]: https://github.com/tractometry/pyAFQ/labels
[link_discussingissues]: https://help.github.com/articles/discussing-projects-in-issues-and-pull-requests

[link_bugs]: https://github.com/yeatmanlab/pyAFQ/labels/bug
[link_firstissue]: https://github.com/yeatmanlab/pyAFQ/labels/good%20first%20issue
[link_enhancement]: https://github.com/yeatmanlab/pyAFQ/labels/enhancement
[link_bugs]: https://github.com/tractometry/pyAFQ/labels/bug
[link_firstissue]: https://github.com/tractometry/pyAFQ/labels/good%20first%20issue
[link_enhancement]: https://github.com/tractometry/pyAFQ/labels/enhancement

[link_pullrequest]: https://help.github.com/articles/creating-a-pull-request-from-a-fork
[link_fork]: https://help.github.com/articles/fork-a-repo/
Expand Down
19 changes: 12 additions & 7 deletions .github/workflows/docbuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,19 @@ name: Documentation build

on: [push, pull_request]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: write

jobs:
build:
runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.11"]

steps:
- name: Checkout repo
Expand All @@ -31,14 +37,13 @@ jobs:
cd docs
make html
- name: Upload docs
uses: actions/upload-artifact@v1
if: matrix.python-version == '3.11'
uses: actions/upload-artifact@v4
with:
name: docs
path: docs/build/html
- name: Publish docs to Github Pages
if: startsWith(github.event.ref, 'refs/tags')
uses: JamesIves/github-pages-deploy-action@releases/v3
uses: JamesIves/github-pages-deploy-action@releases/v4
with:
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}
BRANCH: gh-pages # The branch the action should deploy to.
FOLDER: docs/build/html # The folder the action should deploy.
folder: docs/build/html
2 changes: 1 addition & 1 deletion .github/workflows/docker_pyafq.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
sh ./gpu_docker/docker-build.sh \
"${GITHUB_REF:10}" "nrdg" "11.4.3-devel-ubuntu20.04" "11"

- name: Login to GHCR
- name: Login to GHCR
if: github.ref == 'refs/heads/master' || startsWith(github.event.ref, 'refs/tags')
uses: docker/login-action@v1
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docker_pyafq_cuda12.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ jobs:
sh ./gpu_docker/docker-build.sh \
"${GITHUB_REF:10}" "nrdg" "12.0.1-devel-ubuntu20.04" "12"

- name: Login to GHCR
- name: Login to GHCR
if: github.ref == 'refs/heads/master' || startsWith(github.event.ref, 'refs/tags')
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
registry: ghcr.io
username: nrdg
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_anisotropic_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_basic_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_custom_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_pft_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_reco80_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_reco_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]

steps:
- name: Checkout repo
Expand Down
26 changes: 13 additions & 13 deletions .github/workflows/publish-to-test-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,34 +6,34 @@ jobs:
name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Set up Python 3.9
- uses: actions/checkout@v4
- name: Set up Python 3.11
uses: actions/setup-python@v1
with:
python-version: 3.9
- name: Install pypa/build
python-version: 3.11
- name: Install pep517
run: >-
python -m
pip install
build
pep517
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
pep517.build
--source
--binary
--out-dir dist/
.
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.test_pypi_password }}
repository_url: https://test.pypi.org/legacy/
repository-url: https://test.pypi.org/legacy/
- name: Publish distribution 📦 to PyPI
if: startsWith(github.event.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.pypi_password }}
password: ${{ secrets.pypi_password }}
6 changes: 5 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,18 @@ name: Test suite

on: [push, pull_request]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
build:

runs-on: ubuntu-latest
strategy:
max-parallel: 4
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.10", "3.11"]
nibabel-pre: [true, false]

steps:
Expand Down
2 changes: 1 addition & 1 deletion .zenodo.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"license": "BSD-3-Clause",
"related_identifiers": [
{
"identifier": "http://yeatmanlab.github.io/pyAFQ",
"identifier": "http://tractometry.org/pyAFQ",
"relation": "isPartOf",
"scheme": "url"
}
Expand Down
2 changes: 1 addition & 1 deletion AFQ/data/fetch.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ def read_callosum_templates(as_img=True, resample_to=False):
#
# - atlas: https://www.nitrc.org/projects/pediatricatlas
#
# - pediatric templates: https://github.com/yeatmanlab/AFQ/tree/babyAFQ
# - pediatric templates: https://github.com/tractometry/AFQ/tree/babyAFQ
#
# Templates downloaded from:
#
Expand Down
2 changes: 1 addition & 1 deletion AFQ/tasks/viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def init_viz_backend(viz_backend_spec="plotly_no_gif",
viz_backend_spec : str, optional
Which visualization backend to use.
See Visualization Backends page in documentation for details:
https://yeatmanlab.github.io/pyAFQ/usage/viz_backend.html
https://tractometry.org/pyAFQ/usage/viz_backend.html
One of {"fury", "plotly", "plotly_no_gif"}.
Default: "plotly_no_gif"
"""
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# pyAFQ
Automated Fiber Quantification ... in Python.

For details, see [Documentation](https://yeatmanlab.github.io/pyAFQ)
For details, see [Documentation](https://tractometry.org/pyAFQ)

For further analysis of results, see [AFQ-Insight](https://github.com/richford/AFQ-Insight)

Expand Down
4 changes: 2 additions & 2 deletions bin/pyAFQ
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ usage = \
Runs full AFQ processing as specified in the configuration file.

For details about configuration, see instructions in:
https://yeatmanlab.github.io/pyAFQ/usage/config.html
https://tractometry.org/pyAFQ/usage/config.html

The default configuration file looks like:

Expand Down Expand Up @@ -104,7 +104,7 @@ def parse_cli(arg_dict):
logger.info(
"Your use of pyAFQ is being recorded using Google Analytics. "
"For more information, please refer to the pyAFQ documentation: "
"https://yeatmanlab.github.io/pyAFQ/usage.html#usage-tracking-with-google-analytics. " # noqa
"https://tractometry.org/pyAFQ/usage.html#usage-tracking-with-google-analytics. " # noqa
"To turn this off, use the `--notrack` "
"flag when using the pyAFQ CLI")
import popylar
Expand Down
2 changes: 1 addition & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ help:
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

upload: html
./upload-gh-pages.sh build/html/ pyAFQ yeatmanlab
./upload-gh-pages.sh build/html/ pyAFQ tractometry

.PHONY: distclean realclean

Expand Down
4 changes: 2 additions & 2 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
"icon_links": [
{
"name": "GitHub",
"url": "https://github.com/yeatmanlab/pyAFQ",
"url": "https://github.com/tractometry/pyAFQ",
"icon": "fab fa-github-square",
}]

Expand All @@ -122,7 +122,7 @@

html_context = {
"github_url": "https://github.com",
"github_user": "yeatmanlab",
"github_user": "tractometry",
"github_repo": "pyAFQ",
"github_version": "master",
"doc_path": "docs/source",
Expand Down
2 changes: 1 addition & 1 deletion docs/source/explanations/modeling.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ For an interesting perspective on modeling of tissue properties from diffusion
MRI data, please refer to a recent paper by Novikov and colleagues
[Novikov2018]_.

`This page <https://yeatmanlab.github.io/pyAFQ/reference/methods.rst>` includes
`This page <https://tractometry.org/pyAFQ/reference/methods.rst>` includes
a list of the model parameters that are accessible through the
:class:`AFQ.api.group.GroupAFQ` and :class:`AFQ.api.participant.ParticipantAFQ`
objects.
Expand Down
4 changes: 2 additions & 2 deletions docs/source/howto/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ How to contribute to pyAFQ
~~~~~~~~~~~~~~~~~~~~~

pyAFQ is an open-source software project. This means that you are welcome
to use it (see `LICENSE <https://github.com/yeatmanlab/pyAFQ/blob/master/LICENSE>`_ for details).
to use it (see `LICENSE <https://github.com/tractometry/pyAFQ/blob/master/LICENSE>`_ for details).

It also means that we welcome contributions from developers outside of our
research collaboration and we will credit these contributions appropriately.

Detailed guidelines for contribution are available `here <https://github.com/yeatmanlab/pyAFQ/blob/master/.github/CONTRIBUTING.md>`_.
Detailed guidelines for contribution are available `here <https://github.com/tractometry/pyAFQ/blob/master/.github/CONTRIBUTING.md>`_.
Loading
Loading