Fix ndim test

This commit is contained in:
Johannes Schönberger
2013-12-09 11:44:26 +01:00
parent 50e155e254
commit 48334705c1
+1 -1
View File
@@ -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.")