From 48334705c10b77b3846c4dfb4775cf6ed9428cf5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Sch=C3=B6nberger?= Date: Mon, 9 Dec 2013 11:44:26 +0100 Subject: [PATCH] Fix ndim test --- skimage/feature/template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/skimage/feature/template.py b/skimage/feature/template.py index 0443b1c6..7e289711 100644 --- a/skimage/feature/template.py +++ b/skimage/feature/template.py @@ -100,7 +100,7 @@ def match_template(image, template, pad_input=False, mode='constant', [ 0. , 0. , 0. , 0.125, 0.125, 0.125]], dtype=float32) """ - if image.ndim not in (2, 3): + if image.ndim not in (2, 3) or template.ndim not in (2, 3): raise ValueError("Only 2- and 3-D images supported.") if image.ndim != template.ndim: raise ValueError("Dimensionality of template must match image.")