diff --git a/skimage/util/dtype.py b/skimage/util/dtype.py index 44476e44..b039123c 100644 --- a/skimage/util/dtype.py +++ b/skimage/util/dtype.py @@ -109,8 +109,8 @@ def convert(image, dtype, force_copy=False, uniform=False): prec_loss() if copy: b = np.empty(a.shape, _dtype2(kind, m)) - np.divide(a, 2**(n - m), out=b, dtype=a.dtype, - casting='unsafe') + np.floor_divide(a, 2**(n - m), out=b, dtype=a.dtype, + casting='unsafe') return b else: a //= 2**(n - m)