Skip to content

v1.26.0rc1

Pre-release
Pre-release
Compare
Choose a tag to compare
@charris charris released this 06 Sep 22:36
· 3405 commits to main since this release
v1.26.0rc1
436752e

NumPy 1.26.0 Release Notes

The NumPy 1.26.0 release is a continuation of the 1.25.x release cycle
with the addition of Python 3.12.0 support. Python 3.12 dropped
distutils, consequently supporting it required finding a replacement for
the setup.py/distutils based build system NumPy was using. We have
chosen to use the Meson build system instead, and this is the first
NumPy release supporting it. This is also the first release that
supports Cython 3.0 in addition to retaining 0.29.X compatibility.
Supporting those two upgrades was a large project, over 100 files have
been touched in this release. The changelog doesn't capture the full
extent of the work, special thanks to Ralf Gommers, Sayed Adel, Stéfan
van der Walt, and Matti Picus who did much of the work in the main
development branch.

The highlights of this release are:

  • Python 3.12.0 support.
  • Cython 3.0.0 compatibility.
  • Use of the Meson build system
  • Updated SIMD support
  • f2py fixes, meson and bind(x) support

The Python versions supported in this release are 3.9-3.12.

New Features

Array API v2022.12 support in numpy.array_api

numpy.array_api now full supports the
v2022.12 version
of the array API standard. Note that this does not yet include the optional
fft extension in the standard.

(gh-23789)

Support for the updated Accelerate BLAS/LAPACK library

Support for the updated Accelerate BLAS/LAPACK library, including ILP64
(64-bit integer) support, in macOS 13.3 has been added. This brings
arm64 support, and significant performance improvements of up to 10x for
commonly used linear algebra operations. When Accelerate is selected at
build time, the 13.3+ version will automatically be used if available.

(gh-24053)

meson backend for f2py

f2py in compile mode (i.e. f2py -c) now accepts the
--backend meson option. This is the default option for Python 3.12
on-wards. Older versions will still default to --backend distutils.

To support this in realistic use-cases, in compile mode f2py takes a
--dep flag one or many times which maps to dependency() calls in the
meson backend, and does nothing in the distutils backend.

There are no changes for users of f2py only as a code generator, i.e.
without -c.

(gh-24532)

bind(c) support for f2py

Both functions and subroutines can be annotated with bind(c). f2py
will handle both the correct type mapping, and preserve the unique label
for other C interfaces.

Note: bind(c, name = 'routine_name_other_than_fortran_routine') is
not honored by the f2py bindings by design, since bind(c) with the
name is meant to guarantee only the same name in C and Fortran,
not in Python and Fortran.

(gh-24555)

Improvements

iso_c_binding support for f2py

Previously, users would have to define their own custom f2cmap file to
use type mappings defined by the Fortran2003 iso_c_binding intrinsic
module. These type maps are now natively supported by f2py

(gh-24555)

Build system changes

In this release, NumPy has switched to Meson as the build system and
meson-python as the build backend. Installing NumPy or building a wheel
can be done with standard tools like pip and pypa/build. The
following are supported:

  • Regular installs: pip install numpy or (in a cloned repo)
    pip install .
  • Building a wheel: python -m build (preferred), or pip wheel .
  • Editable installs: pip install -e . --no-build-isolation
  • Development builds through the custom CLI implemented with
    spin: spin build.

All the regular pip and pypa/build flags (e.g.,
--no-build-isolation) should work as expected.

NumPy-specific build customization

Many of the NumPy-specific ways of customizing builds have changed. The
NPY_* environment variables which control BLAS/LAPACK, SIMD,
threading, and other such options are no longer supported, nor is a
site.cfg file to select BLAS and LAPACK. Instead, there are
command-line flags that can be passed to the build via pip/build's
config-settings interface. These flags are all listed in the
meson_options.txt file in the root of the repo. Detailed documented
will be available before the final 1.26.0 release; for now please see
the SciPy "building from source" docs
since most build customization works in an almost identical way in SciPy as it
does in NumPy.

Build dependencies

While the runtime dependencies of NumPy have not changed, the build
dependencies have. Because we temporarily vendor Meson and meson-python,
there are several new dependencies - please see the [build-system]
section of pyproject.toml for details.

Troubleshooting

This build system change is quite large. In case of unexpected issues,
it is still possible to use a setup.py-based build as a temporary
workaround (on Python 3.9-3.11, not 3.12), by copying
pyproject.toml.setuppy to pyproject.toml. However, please open an
issue with details on the NumPy issue tracker. We aim to phase out
setup.py builds as soon as possible, and therefore would like to see
all potential blockers surfaced early on in the 1.26.0 release cycle.

Contributors

A total of 18 people contributed to this release. People with a "+" by
their names contributed a patch for the first time.

  • @DWesl
  • Albert Steppi +
  • Bas van Beek
  • Charles Harris
  • Developer-Ecosystem-Engineering
  • Jake Vanderplas
  • Marten van Kerkwijk
  • Matti Picus
  • Melissa Weber Mendonça
  • Namami Shanker
  • Nathan Goldbaum
  • Ralf Gommers
  • Rohit Goswami
  • Sayed Adel
  • Sebastian Berg
  • Stefan van der Walt
  • Tyler Reddy
  • Warren Weckesser

Pull requests merged

A total of 51 pull requests were merged for this release.

  • #24305: MAINT: Prepare 1.26.x branch for development
  • #24308: MAINT: Massive update of files from main for numpy 1.26
  • #24322: CI: fix wheel builds on the 1.26.x branch
  • #24326: BLD: update openblas to newer version
  • #24327: TYP: Trim down the _NestedSequence.__getitem__ signature
  • #24328: BUG: fix choose refcount leak
  • #24337: TST: fix running the test suite in builds without BLAS/LAPACK
  • #24338: BUG: random: Fix generation of nan by dirichlet.
  • #24340: MAINT: Dependabot updates from main
  • #24342: MAINT: Add back NPY_RUN_MYPY_IN_TESTSUITE=1
  • #24353: MAINT: Update extbuild.py from main.
  • #24356: TST: fix distutils tests for deprecations in recent setuptools...
  • #24375: MAINT: Update cibuildwheel to version 2.15.0
  • #24381: MAINT: Fix codespaces setup.sh script
  • #24403: ENH: Vendor meson for multi-target build support
  • #24404: BLD: vendor meson-python to make the Windows builds with SIMD...
  • #24405: BLD, SIMD: The meson CPU dispatcher implementation
  • #24406: MAINT: Remove versioneer
  • #24409: REL: Prepare for the NumPy 1.26.0b1 release.
  • #24453: MAINT: Pin upper version of sphinx.
  • #24455: ENH: Add prefix to _ALIGN Macro
  • #24456: BUG: cleanup warnings [skip azp][skip circle][skip travis][skip...
  • #24460: MAINT: Upgrade to spin 0.5
  • #24495: BUG: asv dev has been removed, use asv run.
  • #24496: BUG: Fix meson build failure due to unchanged inplace auto-generated...
  • #24521: BUG: fix issue with git-version script, needs a shebang to run
  • #24522: BUG: Use a default assignment for git_hash [skip ci]
  • #24524: BUG: fix NPY_cast_info error handling in choose
  • #24526: BUG: Fix common block handling in f2py
  • #24541: CI,TYP: Bump mypy to 1.4.1
  • #24542: BUG: Fix assumed length f2py regression
  • #24544: MAINT: Harmonize fortranobject
  • #24545: TYP: add kind argument to numpy.isin type specification
  • #24561: BUG: fix comparisons between masked and unmasked structured arrays
  • #24590: CI: Exclude import libraries from list of DLLs on Cygwin.
  • #24591: BLD: fix _umath_linalg dependencies
  • #24594: MAINT: Stop testing on ppc64le.
  • #24602: BLD: meson-cpu: fix SIMD support on platforms with no features
  • #24606: BUG: Change Cython binding directive to "False".
  • #24613: ENH: Adopt new macOS Accelerate BLAS/LAPACK Interfaces, including...
  • #24614: DOC: Update building docs to use Meson
  • #24615: TYP: Add the missing casting keyword to np.clip
  • #24616: TST: convert cython test from setup.py to meson
  • #24617: MAINT: Fixup fromnumeric.pyi
  • #24622: BUG, ENH: Fix iso_c_binding type maps and fix bind(c)...
  • #24629: TYP: Allow binary_repr to accept any object implementing...
  • #24630: TYP: Explicitly declare dtype and generic hashable
  • #24637: ENH: Refactor the typing "reveal" tests using [typing.assert_type]{.title-ref}
  • #24638: MAINT: Bump actions/checkout from 3.6.0 to 4.0.0
  • #24647: ENH: meson backend for f2py
  • #24648: MAINT: Refactor partial load Workaround for Clang

Checksums

MD5

9bcab451e9d0eadcc00ca8ce2f5938e7  numpy-1.26.0rc1-cp310-cp310-macosx_10_9_x86_64.whl
4b1c33742eaba91fb2a3fdf531c086f8  numpy-1.26.0rc1-cp310-cp310-macosx_11_0_arm64.whl
6adb6b6a762f256f5ca6c82b6a302912  numpy-1.26.0rc1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
c4dbed88820255134bcae15d02c658ed  numpy-1.26.0rc1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
72dbf4449513dc1ef51b59266199cf37  numpy-1.26.0rc1-cp310-cp310-musllinux_1_1_x86_64.whl
c25812360af41a904324503d7ca02cce  numpy-1.26.0rc1-cp310-cp310-win_amd64.whl
6bbaeaa8c54a084c749ad4ede57bbeb6  numpy-1.26.0rc1-cp311-cp311-macosx_10_9_x86_64.whl
f0585ce50c22914e0f039fd817a847c4  numpy-1.26.0rc1-cp311-cp311-macosx_11_0_arm64.whl
79e7deab2a43552aa4f4097183e6287d  numpy-1.26.0rc1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
1f94542339a4e6327914398b7785876b  numpy-1.26.0rc1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
3c3c3ea226bcf0e92796da621c0ac7fe  numpy-1.26.0rc1-cp311-cp311-musllinux_1_1_x86_64.whl
5d6bca28d5c43fc839e4d8eff3b3a35c  numpy-1.26.0rc1-cp311-cp311-win_amd64.whl
94df9fa058c650073de474555cc6f0dc  numpy-1.26.0rc1-cp312-cp312-macosx_10_9_x86_64.whl
2ef744a42b9db31f7ce4a0c7cb8b546d  numpy-1.26.0rc1-cp312-cp312-macosx_11_0_arm64.whl
cf2b61c8480245995348fc2ddc4f556f  numpy-1.26.0rc1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
18cea65bce62f924c34d3b0148db4669  numpy-1.26.0rc1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
5aede55c449bdc62e59230f786faa400  numpy-1.26.0rc1-cp312-cp312-musllinux_1_1_x86_64.whl
15c8199396b8adcfc9a6e4fb730d6faf  numpy-1.26.0rc1-cp312-cp312-win_amd64.whl
c9d97598b2bcaac53dc082106d0bc926  numpy-1.26.0rc1-cp39-cp39-macosx_10_9_x86_64.whl
8359d919806089cf48086c923e1b2e81  numpy-1.26.0rc1-cp39-cp39-macosx_11_0_arm64.whl
4322ecb6dd6db9dc704f54603622da72  numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
a275abd27929fa7428c94b6c493798d7  numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
a374c440c6233a78b0bb1bf11776e48f  numpy-1.26.0rc1-cp39-cp39-musllinux_1_1_x86_64.whl
3e540eca6628510c604099a6c0a79fb5  numpy-1.26.0rc1-cp39-cp39-win_amd64.whl
a7b15d45d9b18bd2f065be1eafa3cfea  numpy-1.26.0rc1-pp39-pypy39_pp73-macosx_10_9_x86_64.whl
b7e926a0415c30df7010400936922cd7  numpy-1.26.0rc1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
8430d4acc483c66d76b8263ac90195e6  numpy-1.26.0rc1-pp39-pypy39_pp73-win_amd64.whl
23bf7c39807a9cce5c8ea0ba293b7dd9  numpy-1.26.0rc1.tar.gz

SHA256

abe4b4414edd3dc61a2f6df6f0aa7711c654fc59f41a0eeae4c34b9bfc18aa22  numpy-1.26.0rc1-cp310-cp310-macosx_10_9_x86_64.whl
0e294b045e6fa8f071e4c88836b0df2167fc74ff8561138aa5cd69d1ee98b15e  numpy-1.26.0rc1-cp310-cp310-macosx_11_0_arm64.whl
38324eb42bcd45db0b509d02325cb0e3058b6cf05beaf5bd02c221a3133cc9ff  numpy-1.26.0rc1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
302003be9baeb79f07153426544f87f534eb9fe3b8399ac8ee8420f5cfd7ed5c  numpy-1.26.0rc1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
f8a9eb3d3f74978cb155a12a77046dae5b8d76bfcf56f76cc92f0d5976857ef9  numpy-1.26.0rc1-cp310-cp310-musllinux_1_1_x86_64.whl
a9b4723216f7970f571d0d71935b32ffe0eacd011befbaa977f34e928ece8c71  numpy-1.26.0rc1-cp310-cp310-win_amd64.whl
5db29b5d2c73a05ef7ed2a37a1ca8f9391579c402a57f6e0944daf755cf7d437  numpy-1.26.0rc1-cp311-cp311-macosx_10_9_x86_64.whl
180ef984616afd4d746961ac8c874ddd5d547ba8f7dd8a58c30bde398c95d15c  numpy-1.26.0rc1-cp311-cp311-macosx_11_0_arm64.whl
0e3c8d925204ba0aa887244adec030e71003b828d24731f9feb01526aed76458  numpy-1.26.0rc1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
01851e82e3256a6c0088e43e69279a0c96214bafa1be326c7a87390d91eb7d44  numpy-1.26.0rc1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
26571d9f63f49e7612fcfc4375ad23d6882e951bca335115ce440add1a565556  numpy-1.26.0rc1-cp311-cp311-musllinux_1_1_x86_64.whl
f10ef55f19e6634c10b87c5a7c3687461fe950680ebe16e85c03905bcbf6b205  numpy-1.26.0rc1-cp311-cp311-win_amd64.whl
b28cc269bbdd2b6e005241100a97460fdd574ce495fa0eeda3d290d8fd0c66fa  numpy-1.26.0rc1-cp312-cp312-macosx_10_9_x86_64.whl
965fedf11de8b621a20fe7182b95ef9ee76764bc1fc288e5b2cb6e8440372560  numpy-1.26.0rc1-cp312-cp312-macosx_11_0_arm64.whl
2ff5f4f14a772e0f86a250d6db86c4121bc1ce7d788f64053e82638e735bb61b  numpy-1.26.0rc1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
290c9be374026e63c6e5f5099a06c2cdfea33ff2935e7f46fcd9a1b38728c80c  numpy-1.26.0rc1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
d915b8e07e277a443da4525fd36403ca4f14dcb9cd237ab6a9aff73119b71820  numpy-1.26.0rc1-cp312-cp312-musllinux_1_1_x86_64.whl
3042f503964e1e5decacdfd0eeb0ed9eadf9b70ad1a8bb085ee277bd3ddf4362  numpy-1.26.0rc1-cp312-cp312-win_amd64.whl
3080a9ec21470a9b485e92a09baedb5136468d89b2f2a1896a27fa9e36341af2  numpy-1.26.0rc1-cp39-cp39-macosx_10_9_x86_64.whl
dd42d283561d0fe8911ff0576495a09928a3b53de2c5a6d1959e34a393e8ff65  numpy-1.26.0rc1-cp39-cp39-macosx_11_0_arm64.whl
d881436a9b325fa357b7ac32aac0be8c74921ab0f09d47139553e5da23383bc6  numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
1c6967bfadb4723aa025a8a9870ff554f1b03c428740167ac6616c7df0c9d817  numpy-1.26.0rc1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
69580fae06143eb07300d1f1dace92f22dd4d47600e4832bea2b1685d7bc89e9  numpy-1.26.0rc1-cp39-cp39-musllinux_1_1_x86_64.whl
5241d904c9b651183c48b5b7f49e76715d96177def6a7a9bb5aa9e9984000786  numpy-1.26.0rc1-cp39-cp39-win_amd64.whl
6aa0bda5c93d09f8a0253cc902c6dc66de30228c08bd746d4cb4c73d7daee5bc  numpy-1.26.0rc1-pp39-pypy39_pp73-macosx_10_9_x86_64.whl
b6e353a18acbbd0253115477879fef4253e284891f37d08eeda6bf77556d1534  numpy-1.26.0rc1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
53a6d1f073f8cad9c97a6e7f16eac552475db8246ce379c961edeafb3d0e3152  numpy-1.26.0rc1-pp39-pypy39_pp73-win_amd64.whl
49a8cafece27db51fd9ec78c044546b15b0c9bf95466c57ada9eeae64075c2f8  numpy-1.26.0rc1.tar.gz