From 1975a3425813d9afe4aaf619f6df3e52db0eb44e Mon Sep 17 00:00:00 2001 From: Serge Koudoro Date: Tue, 25 Jun 2024 19:27:50 +0300 Subject: [PATCH] FIX: `ptp` was removed from the ndarray class in NumPy 2.0. Use np.ptp(arr, ...) instead. --- fury/colormap.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fury/colormap.py b/fury/colormap.py index 932191227..4d9a5c0b1 100644 --- a/fury/colormap.py +++ b/fury/colormap.py @@ -669,7 +669,7 @@ def rgb2hsv(rgb): out_v = rgb.max(-1) # -- S channel - delta = rgb.ptp(-1) + delta = np.ptp(rgb, -1) # Ignore warning for zero divided by zero old_settings = np.seterr(invalid="ignore") out_s = delta / out_v