CIL icon indicating copy to clipboard operation
CIL copied to clipboard

support numpy v2

Open casperdcl opened this issue 1 year ago • 1 comments

  • numpy>=2 was released on 16 June 2024
  • numpy>=2.1.0 was released on 18 Aug 2024 and supports py3.13
  • numpy<2 ended support on 16 Sep 2025

From migration guide:

np._set_promotion_state("weak_and_warn")

[Optionally,] use warnings.simplefilter to raise it as an error for a traceback [...] Unfortunately, running this may flag many changes that are irrelevant in practice.

related

  • #1839
  • #2030
  • #2034
  • #2090
  • #2092
  • https://numpy.org/devdocs/numpy_2_0_migration_guide.html#changes-to-numpy-data-type-promotion
  • https://numpy.org/neps/nep-0050-scalar-promotion.html#nep50

casperdcl avatar Aug 29 '24 11:08 casperdcl

Mantid Imaging use the 'ruff' code linter This can be used to flag numpy 2 deprecations Potentially could just run ruff with the numpy rule

lauramurgatroyd avatar Apr 25 '25 10:04 lauramurgatroyd