mirror of
https://github.com/wassname/scikit-image.git
synced 2026-07-10 05:07:07 +08:00
Reduce number of specializations
This commit is contained in:
@@ -10,10 +10,8 @@ def _convolve(image, selem, out, cval):
|
||||
selem_sum = np.sum(selem)
|
||||
if selem_sum < 2 ** 8:
|
||||
out_dtype = np.uint8
|
||||
elif selem_sum < 2 ** 16:
|
||||
out_dtype = np.uint16
|
||||
else:
|
||||
out_dtype = np.uint32
|
||||
out_dtype = np.intp
|
||||
|
||||
if out is None:
|
||||
out = np.zeros_like(image, dtype=out_dtype)
|
||||
|
||||
Reference in New Issue
Block a user