diff --git a/news/numpy_dep.rst b/news/numpy_dep.rst new file mode 100644 index 0000000..883e78f --- /dev/null +++ b/news/numpy_dep.rst @@ -0,0 +1,23 @@ +**Added:** + +* + +**Changed:** + +* + +**Deprecated:** + +* + +**Removed:** + +* + +**Fixed:** + +* Fixed deprecation warning presented by numpy2 + +**Security:** + +* diff --git a/src/diffpy/fourigui/fourigui.py b/src/diffpy/fourigui/fourigui.py index 219a87b..c3c632d 100755 --- a/src/diffpy/fourigui/fourigui.py +++ b/src/diffpy/fourigui/fourigui.py @@ -394,8 +394,9 @@ def fft(self): def perform_fft(fftholder): fftholder = np.nan_to_num(fftholder) size = list(fftholder.shape) + axes = list(range(fftholder.ndim)) fftholder = np.fft.ifftshift(fftholder) - fftholder = np.fft.fftn(fftholder, s=size, norm="ortho") + fftholder = np.fft.fftn(fftholder, s=size, axes=axes, norm="ortho") fftholder = np.fft.fftshift(fftholder) fftholder = fftholder.real return fftholder