From df5d8f00d8a78e8adf7081ead8e805daae5c84ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erik=20Fr=C3=B6jdh?= Date: Tue, 5 May 2026 09:21:11 +0200 Subject: [PATCH] typed as np.int32 (#1446) --- python/slsdet/dacs.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/python/slsdet/dacs.py b/python/slsdet/dacs.py index 547a43277..f4da41526 100755 --- a/python/slsdet/dacs.py +++ b/python/slsdet/dacs.py @@ -96,7 +96,7 @@ class NamedDacs: """ Read the dacs into a numpy array with dimensions [ndacs, nmodules] """ - dac_array = np.zeros((len(self._dacnames), len(self._detector))) + dac_array = np.zeros((len(self._dacnames), len(self._detector)), dtype = np.int32) for i, _d in enumerate(self): dac_array[i,:] = _d[:] return dac_array @@ -108,7 +108,7 @@ class NamedDacs: """ Set the dacs from an numpy array with dac values. [ndacs, nmodules] """ - dac_array = dac_array.astype(np.int) + dac_array = dac_array.astype(np.int32) for i, _d in enumerate(self): _d[:] = dac_array[i] @@ -170,7 +170,7 @@ class DetectorDacs: """ Read the dacs into a numpy array with dimensions [ndacs, nmodules] """ - dac_array = np.zeros((len(self._dacs), len(self._detector))) + dac_array = np.zeros((len(self._dacs), len(self._detector)), dtype = np.int32) for i, _d in enumerate(self): dac_array[i,:] = _d[:] return dac_array @@ -182,7 +182,7 @@ class DetectorDacs: """ Set the dacs from an numpy array with dac values. [ndacs, nmodules] """ - dac_array = dac_array.astype(np.int) + dac_array = dac_array.astype(np.int32) for i, _d in enumerate(self): _d[:] = dac_array[i]