From 896df137db672707e8e8de03655fb8e68116b84a Mon Sep 17 00:00:00 2001
From: Hugo Buddelmeijer <hugo@buddelmeijer.nl>
Date: Mon, 18 Sep 2023 19:11:46 +0200
Subject: [PATCH] Fix deprecation warnings

---
 setup.cfg                      |  4 +++-
 src/micado/main/ImstatExtra.py | 10 +++++-----
 2 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/setup.cfg b/setup.cfg
index 5211331a4..a12e0af83 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -2,8 +2,10 @@
 filterwarnings =
     error
     # Triggered by ScopeSIM:
-    ignore:In a future version top level function calls will be removed:DeprecationWarning:scopesim
+    ignore:In a future version top level function calls will be removed:DeprecationWarning
     ignore:Please use `zoom`:DeprecationWarning:scopesim
+    ignore:`np.bool8` is a deprecated alias for `np.bool_`:DeprecationWarning
+    ignore:Conversion of an array with ndim > 0 to a scalar is deprecated:DeprecationWarning
     # Dividing by 0:
     ignore:invalid value encountered in true_divide:RuntimeWarning
     ignore:invalid value encountered in divide:RuntimeWarning
diff --git a/src/micado/main/ImstatExtra.py b/src/micado/main/ImstatExtra.py
index 23e500299..78ac35d6f 100644
--- a/src/micado/main/ImstatExtra.py
+++ b/src/micado/main/ImstatExtra.py
@@ -22,8 +22,8 @@ class ImstatExtra(MObject):
         # in particular in combination with storing to FITS files and
         # reading the number back. At least for certain combinations
         # of numpy and astropy, e.g. 1.21.1 and 4.3.post1.
-        self.min = fitsfloat(float(numpy.round_(numpy.min(images), 14)))
-        self.max = fitsfloat(float(numpy.round_(numpy.max(images), 14)))
-        self.mean = fitsfloat(float(numpy.round_(numpy.mean(images), 14)))
-        self.std = fitsfloat(float(numpy.round_(numpy.std(images), 14)))
-        self.median = fitsfloat(float(numpy.round_(numpy.median(images), 14)))
+        self.min = fitsfloat(float(numpy.round(numpy.min(images), 14)))
+        self.max = fitsfloat(float(numpy.round(numpy.max(images), 14)))
+        self.mean = fitsfloat(float(numpy.round(numpy.mean(images), 14)))
+        self.std = fitsfloat(float(numpy.round(numpy.std(images), 14)))
+        self.median = fitsfloat(float(numpy.round(numpy.median(images), 14)))
-- 
GitLab