From 0859b3662e345b45da52186dc0ba832dcf0653d1 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Fri, 30 Jan 2015 21:01:45 -0600 Subject: [PATCH] Avoid creating an int64 array --- skimage/novice/_novice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/skimage/novice/_novice.py b/skimage/novice/_novice.py index 28df15d4..24c2ff0e 100644 --- a/skimage/novice/_novice.py +++ b/skimage/novice/_novice.py @@ -281,8 +281,8 @@ class Picture(object): if isinstance(color, six.string_types): color = color_dict[color] rgb_size = tuple(size) + (len(color),) + color = np.array(color, dtype=np.uint8) array = np.ones(rgb_size, dtype=np.uint8) * color - array = array.astype(np.uint8) # Force RGBA internally (use max alpha) if array.shape[-1] == 3: