Skip to content

Deprecation warnings from numpy fft  #230

Closed
@asmeurer

Description

@asmeurer

The numpy.array_api has several test failures due to data-apis/array-api#720. But additionally, there are also these warnings, which should be looked into:

array_api_tests/test_fft.py::test_fftn
  /Users/aaronmeurer/Documents/numpy/numpy/fft/_pocketfft.py:857: DeprecationWarning: `axes` should not be `None` if `s` is not `None` (Deprecated in NumPy 2.0). In a future version of NumPy, this will raise an error and `s[i]` will correspond to the size along the transformed axis specified by `axes[i]`. To retain current behaviour, pass a sequence [0, ..., k-1] to `axes` for an array of dimension k.
    return _raw_fftnd(a, s, axes, fft, norm)

array_api_tests/test_fft.py: 16 warnings
  /Users/aaronmeurer/Documents/numpy/numpy/array_api/fft.py:190: DeprecationWarning: `axes` should not be `None` if `s` is not `None` (Deprecated in NumPy 2.0). In a future version of NumPy, this will raise an error and `s[i]` will correspond to the size along the transformed axis specified by `axes[i]`. To retain current behaviour, pass a sequence [0, ..., k-1] to `axes` for an array of dimension k.
    res = Array._new(np.fft.irfftn(x._array, s=s, axes=axes, norm=norm))

We should also double check if the standard is correct here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions