ITADN
nipy/nibabel

版本发布 8

5.4.1
? · 2026-03-10

## Release notes Bug-fix release in the 5.4.x series. This release addresses test failures on shallow clones or when run with ``python -m pytest`` in Python 3.14+. Bug fixes --------- * Adjust tests to not depend on how pytest is run, or deep clones (#1478) (CM) Maintenance ----------- * Consolidate environment management for development tasks to ensure tox and pre-commit stay in sync. (#1475) (CM, reviewed by Rémi Gau) * Update pre-commit and ruff configurations (#1467) (Rémi Gau, reviewed by CM) ## New Contributors * @Remi-Gau made their first contribution in https://github.com/nipy/nibabel/pull/1467 **Full Changelog**: https://github.com/nipy/nibabel/compare/5.4.0...5.4.1

5.3.3
? · 2025-12-05

[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.17833605.svg)](https://doi.org/10.5281/zenodo.17833605) ## Release notes Bug-fix release in the 5.3.x series. ## Bug fixes * Fix frame order for single-frame DICOM files (pr/1387) (Brendan Moloney, reviewed by CM) * Replace :class:`dict` literal with :class:`set` in test. (pr/1382) (CM) **Full Changelog**: https://github.com/nipy/nibabel/compare/5.3.2...5.3.3

5.3.1
? · 2024-10-15

## Release notes Bug-fix release in the 5.3.x series. Bug fixes --------- * Restore access to private attribute ``Nifti1Extension._content`` to unbreak subclasses that did not use public accessor methods. (#1378) (CM, reviewed by Basile Pinsard) * Remove test order dependency in ``test_api_validators`` (#1377) (CM)

5.2.1
? · 2024-02-27

## Release notes Bug-fix release in the 5.2.x series. Enhancements ------------ * Support "flat" ASCII-encoded GIFTI DataArrays (#1298) (PM, reviewed by CM) Bug fixes --------- * Tolerate missing ``git`` when reporting version info (#1286) (CM, reviewed by Yuri Victorovich) * Handle Siemens XA30 derived DWI DICOMs (#1296) (CM, reviewed by YOH and Mathias Goncalves) Maintenance ----------- * Add tool for generating GitHub-friendly release notes (#1284) (CM) * Accommodate pytest 8 changes (#1297) (CM) **Full Changelog**: https://github.com/nipy/nibabel/compare/5.2.0...5.2.1

5.2.0
? · 2023-12-12

Release notes ------------- New feature release in the 5.2.x series. This release requires a minimum Python of 3.8 and NumPy 1.20, and has been tested up to Python 3.12 and NumPy 1.26. New features ------------ * Add generic [Pointset](https://nipy.org/nibabel/reference/nibabel.pointset.html#nibabel.pointset.Pointset) and regularly spaced [NDGrid](https://nipy.org/nibabel/reference/nibabel.pointset.html#nibabel.pointset.NDGrid) data structures in preparation for coordinate transformation and resampling (#1251) (CM, reviewed by Oscar Esteban) Enhancements ------------ * Add [copy](https://nipy.org/nibabel/reference/nibabel.arrayproxy.html#nibabel.arrayproxy.ArrayProxy.copy) method to [ArrayProxy](https://nipy.org/nibabel/reference/nibabel.arrayproxy.html#nibabel.arrayproxy.ArrayProxy) (#1255) (CM, reviewed by Paul McCarthy) * Permit [to_xml](https://nipy.org/nibabel/reference/nibabel.xmlutils.html#nibabel.xmlutils.XmlSerializable.to_xml) to pass keyword arguments to [tostring](https://docs.python.org/3/library/xml.etree.elementtree.html#xml.etree.ElementTree.tostring) (#1258) (CM) * Allow user expansion (e.g., ``~/...``) in strings passed to functions that accept paths (#1260) (Reinder Vos de Wael, reviewed by CM) * Expand CIFTI-2 brain structures to permit synonyms (#1256) (CM, reviewed by Mathias Goncalves) * Annotate [SpatialImage](https://nipy.org/nibabel/reference/nibabel.spatialimages.html#nibabel.spatialimages.SpatialImage) as accepting ``affine=None`` argument (#1253) (Blake Dewey, reviewed by CM) * Warn on invalid MINC2 spacing declarations, treat as missing (#1237) (Peter Suter, reviewed by CM) * Refactor [find_private_section](https://nipy.org/nibabel/reference/nibabel.nicom.html#nibabel.nicom.utils.find_private_section) for improved readability and maintainability (#1228) (MB, reviewed by CM) Bug fixes --------- * Resolve test failure related to randomly generated invalid case (#1221) (CM) Documentation ------------- * Remove references to NiPy data packages from documentation (#1275) (Dimitri Papadopoulos, reviewed by CM, MB) Maintenance ----------- * Quality of life improvements for CI, including color output and OIDC publishing (#1282) (CM) * Patch for NumPy 2.0 pre-release compatibility (#1250) (Mathieu Scheltienne and EL, reviewed by CM) * Add spellchecking to tox, CI and pre-commit (#1266) (CM) * Add py312-dev-x64 environment to Tox to test NumPy 2.0 pre-release compatibility (#1267) (CM, reviewed by EL) * Resurrect tox configuration to cover development workflows and CI checks (#1262) (CM) * Updates for Python 3.12 support (pr/1247, pr/1261, pr/1273) (CM) * Remove uses of deprecated ``numpy.compat.py3k`` module (#1243) (Eric Larson, reviewed by CM) * Various fixes for typos and style issues detected by Codespell, pyupgrade and refurb (pr/1263, pr/1269, pr/1270, pr/1271, pr/1276) (Dimitri Papadopoulos, reviewed by CM) * Use stable argsorts in PARREC tests to ensure consistent behavior on systems with AVX512 SIMD instructions and numpy 1.25 (#1234) (CM) * Resolve CodeCov submission failures (#1224) (CM) * Link to logo with full URL to avoid broken links in PyPI (#1218) (CM, reviewed by Zvi Baratz) API changes and deprecations ---------------------------- * The [nibabel.pydicom_compat](https://nipy.org/nibabel/reference/nibabel.pydicom_compat.html) module is deprecated and will be removed in NiBabel 7.0. (#1280) * The [int_to_float](https://nipy.org/nibabel/reference/nibabel.casting.html#nibabel.casting.int_to_float) and [as_int](https://nipy.org/nibabel/reference/nibabel.casting.html#nibabel.casting.as_int) functions are no longer needed to work around NumPy deficiencies and have been deprecated (#1272) (CM, reviewed by EL) ## New Contributors * @petsuter made their first contribution in https://github.com/nipy/nibabel/pull/1237 * @blakedewey made their first contribution in https://github.com/nipy/nibabel/pull/1253 * @ReinderVosDeWael made their first contribution in https://github.com/nipy/nibabel/pull/1260 * @mscheltienne made their first contribution in https://github.com/nipy/nibabel/pull/1250 **Full Changelog**: https://github.com/nipy/nibabel/compare/5.1.0...5.2.0

5.1.0
? · 2023-04-03

New feature release in the 5.1.x series. Most work on NiBabel so far has been by Matthew Brett (MB), Chris Markiewicz (CM), Michael Hanke (MH), Marc-Alexandre Côté (MC), Ben Cipollini (BC), Paul McCarthy (PM), Chris Cheng (CC), Yaroslav Halchenko (YOH), Satra Ghosh (SG), Eric Larson (EL), Demian Wassermann, Stephan Gerhard and Ross Markello (RM). References like "pr/298" refer to github pull request numbers. Enhancements ------------ * Make `imagestats` available with ``import nibabel`` (pr/1208) (Fabian Perez, reviewed by CM) * Use symmetric threshold for identifying unit quaternions on qform calculations (pr/1182) (CM, reviewed by MB) * Type annotations for `nibabel.loadsave` (pr/1213) and `nibabel.spatialimages.SpatialImage` APIs (pr/1179), `nibabel.deprecated`, `nibabel.deprecator`, `nibabel.onetime` and `nibabel.optpkg` modules (pr/1188), `nibabel.volumeutils` (pr/1189), `nibabel.filename_parser` and `nibabel.openers` (pr/1197) (CM, reviewed by Zvi Baratz) Bug fixes --------- * Require explicit overrides to write GIFTI files that contain data arrays with data types not permitted by the GIFTI standard (pr/1199) (CM, reviewed by Alexis Thual) Maintenance ----------- * Move compression detection logic into a private ``nibabel._compression`` module, resolving unexpected errors from pyzstd. (pr/1212) (CM) * Improved consistency of docstring formatting (pr/1200) (Zvi Baratz, reviewed by CM) * Modernized README text (pr/1195) (Zvi Baratz, reviewed by CM) * Updated README badges to include package distributions (pr/1192) (Horea Christian, reviewed by CM) * Removed all dependencies on distutils and setuptools (pr/1190) (CM, reviewed by Zvi Baratz) * Add a ``_version.pyi`` stub to allow mypy to run without building nibabel (pr/1210) (CM) ## New Contributors * @TheChymera made their first contribution in https://github.com/nipy/nibabel/pull/1192 * @Factral made their first contribution in https://github.com/nipy/nibabel/pull/1208 **Full Changelog**: https://github.com/nipy/nibabel/compare/5.0.1...5.1.0

5.0.1
? · 2023-02-12

Bug-fix release in the 5.0.x series. Most work on NiBabel so far has been by Matthew Brett (MB), Chris Markiewicz (CM), Michael Hanke (MH), Marc-Alexandre Côté (MC), Ben Cipollini (BC), Paul McCarthy (PM), Chris Cheng (CC), Yaroslav Halchenko (YOH), Satra Ghosh (SG), Eric Larson (EL), Demian Wassermann, Stephan Gerhard and Ross Markello (RM). References like "pr/298" refer to github pull request numbers. Bug fixes --------- * Support ragged voxel arrays in `ParcelsAxis` (pr/1194) (Michiel Cottaar, reviewed by CM) * Return to cwd on exception in `InTemporaryDirectory` (pr/1184) (CM) Maintenance ----------- * Add ``py.typed`` to module root to enable use of types in downstream projects (CM, reviewed by Fernando Pérez-Garcia) * Cache git-archive separately from Python packages in GitHub Actions (pr/1186) (CM, reviewed by Zvi Baratz)

5.0.0
? · 2023-01-09

New feature release in the 5.0.x series. Most work on NiBabel so far has been by Matthew Brett (MB), Chris Markiewicz (CM), Michael Hanke (MH), Marc-Alexandre Côté (MC), Ben Cipollini (BC), Paul McCarthy (PM), Chris Cheng (CC), Yaroslav Halchenko (YOH), Satra Ghosh (SG), Eric Larson (EL), Demian Wassermann, Stephan Gerhard and Ross Markello (RM). New features ------------ * `SerializableImage` now has `to_stream()` and `from_stream()` methods to read/write streams implementing the `io.IOBase` interface. A `from_url()` method enables loading images from URLs. (pr/1129) (CM, reviewed by MB) * `TrkFile` supports TRKv3, an undocumented but generally compatible variant of TRKv2. (pr/1125) (CM) Enhancements ------------ * Support multiline header fields in `TCKFile` (pr/1175) (CM, reviewed by Matt Cieslak) * Make layout order an initialization parameter of `ArrayProxy` (pr/1131) (CM, reviewed by MB) * Initial support for type annotations. (pr/1115, pr/1178) (CM, reviewed by Zvi Baratz) Bug fixes --------- * Handle extension/file-format mismatches implemented incompletely in pr/1013 (pr/1138) (CM, reviewed by Thomas Phil) * Improve handling of invalid TCK files, which could sometimes cause an infinite loop (pr/1140) (Anibal Solon, reviewed by CM) * Clean up ECAT test case that left filehandle open and failed to use class variables (pr/1155) (Dimitri Papadopoulos, reviewed by CM) Maintenance ----------- * Simplify TCK reading code by assuming files are open in binary mode (pr/1142) (Anibal Solon, reviewed by MC, CM) * Code support for tests covering deprecated functionality (pr/1159) (CM) * Miscellaneous code cleanups (pr/1148, pr/1149, pr/1153, pr/1154, pr/1156) (Dimitri Papadopoulos, reviewed by CM) * Update CI to build, test and deploy PyPI artifacts (pr/1134) (CM, reviewed by MB) * Transition from `setup.cfg` to `pyproject.toml` package configuration (pr/1133) (CM, reviewed by MB) * Addressed race conditions preventing running tests with [pytest-xdist][]. (pr/1157, pr/1158) (CM, reviewed by Christian Haselgrove) * Apply [blue][] and [isort][] auto-formatters and provide [pre-commit][] configuration to reduce human burden of style guidelines. (pr/1124, pr/1165, pr/1169) (CM and Zvi Baratz) * Manage versioning with [setuptools_scm][] (pr/1171) (CM, reviewed by Zvi Baratz) * Reduce installed package size by excluding very large test file (pr/1176) (CM, reviewed by Zvi Baratz) API changes and deprecations ---------------------------- * Passing an ``int64`` array to `Nifti1Image` without a header or dtype argument will raise a ``ValueError``. (pr/1173) (CM) * `tmpdirs.TemporaryDirectory` is deprecated in favor of `tempfile.TemporaryDirectory`. (pr/1172) (CM, reviewed by Zvi Baratz) * The ``nisext`` package is deprecated and will be removed in NiBabel 6.0. (pr/1170) (CM, reviewed by MB) * Drop support for Python 3.7, Numpy < 1.19 (pr/1177) (CM) * The following deprecated functions and methods will now raise ``ExpiredDeprecationError``s * `nibabel.loadsave.read_img_data` * `nibabel.dataobj_images.DataobjImage.get_data` * `nibabel.loadsave.guessed_image_type` * `nibabel.onetime.setattr_on_read` * `nibabel.orientations.flip_axis` * Modules, classes and functions that expired at 4.0 were fully removed. ``ExpiredDeprecationError``\s will now be ``AttributeError``\s. [blue]: https://blue.readthedocs.io [isort]: https://pycqa.github.io/isort/ [pre-commit]: https://pre-commit.com/ [pytest-xdist]: https://pytest-xdist.readthedocs.io [setuptools_scm]: https://github.com/pypa/setuptools_scm