-
Notifications
You must be signed in to change notification settings - Fork 901
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
Add support for Python 3.11, require NumPy 1.23+ #15111
Add support for Python 3.11, require NumPy 1.23+ #15111
Conversation
Co-authored-by: Bradley Dice <bdice@bradleydice.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have pushed a few changes to this PR to align conda & wheel builds to both build against NumPy 1.23 and require it as a minimum version at runtime
Highlighted relevant changes below
Happy to discuss further as needed
@@ -65,6 +65,7 @@ requirements: | |||
- scikit-build-core >=0.7.0 | |||
- setuptools | |||
- dlpack >=0.5,<0.6.0a0 | |||
- numpy 1.23 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As NumPy is used at build time, this now adds it to requirements/host
@@ -83,7 +84,7 @@ requirements: | |||
- pandas >=2.0,<2.2.2dev0 | |||
- cupy >=12.0.0 | |||
- numba >=0.57 | |||
- numpy >=1.21 | |||
- {{ pin_compatible('numpy', max_pin='x') }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Switch to using pin_compatible
with NumPy to ensure the minimum version allowed at runtime matches what we built with and any NumPy version (pre-2.0.0) is allowed
- output_types: pyproject | ||
packages: | ||
# Hard pin the patch version used during the build. | ||
# Sync with conda build constraint & wheel run constraint. | ||
- numpy==1.23.* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the same NumPy pin the conda packages use to build. It is now used here to align the wheel packages
run_common: | ||
common: | ||
- output_types: [conda, requirements, pyproject] | ||
packages: | ||
- fsspec>=0.6.0 | ||
- *numpy | ||
- numpy>=1.23 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both conda & wheel packages now have the same lower bound on NumPy
@@ -625,7 +633,7 @@ dependencies: | |||
- output_types: pyproject | |||
packages: | |||
- msgpack | |||
- &tokenizers tokenizers==0.13.1 | |||
- &tokenizers tokenizers==0.15.2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've bumped tokenizers to 0.15.2 so we can get Python 3.11 binaries.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Incompatible with transformers==4.24.0
:(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bumped transformers to 4.38.1.
tensor = torch.tensor(index) | ||
got = cudf.Index(tensor) | ||
assert_eq(got, index) | ||
# TODO: This test fails with PyTorch 2. Is it still expected to be valid? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed a change 2f0a8a8 to unblock CI, and also rolled it out to a separate PR #15188. See my notes there for discussion and next steps. https://github.com/rapidsai/cudf/pull/15188/files#r1506969204
I would like to merge this test change as-is, to keep the main goal of Python 3.11 support moving. We can handle any further discussion of the issue in https://github.com/rapidsai/cudf/pull/15188/files#r1506969204.
CI failed due to the dask tokenizing bug that was fixed in #15187. I will merge the upstream to rerun CI now. |
/merge |
Hooray! 🥳 Thanks everyone 👏 Glad to have this complete |
This PR contains a few minor improvements for `__cuda_array_interface__` and its tests. Found while working on #15111. Authors: - Bradley Dice (https://github.com/bdice) Approvers: - GALI PREM SAGAR (https://github.com/galipremsagar) URL: #15188
Description
Contributes to rapidsai/build-planning#3
This PR adds support for Python 3.11.
It also bumps uses of
NumPy
tonumpy>=1.23
, see rapidsai/build-planning#3 (comment).Notes for Reviewers
This is part of ongoing work to add Python 3.11 support across RAPIDS.
The Python 3.11 CI workflows introduced in rapidsai/shared-workflows#176 are optional... they are not yet required to run successfully for PRs to be merged.
This PR can be merged once all jobs are running successfully (including the non-required jobs for Python 3.11). The CI logs should be verified that the jobs are building and testing with Python 3.11.
See rapidsai/shared-workflows#176 for more details.
(created with rapids-reviser)
Checklist