Fix shape unpacking ((height, width), not (w, h)).

This commit is contained in:
Tony S Yu
2012-03-30 10:18:03 -04:00
parent 4c3f8a36ba
commit 8dbf6f4c58
+1 -1
View File
@@ -33,7 +33,7 @@ ax2.set_title('image')
# highlight matched region
xy = np.unravel_index(np.argmax(result), result.shape)[::-1] #-1 flips ij to xy
wface, hface = head.shape
hface, wface = head.shape
rect = plt.Rectangle(xy, wface, hface, edgecolor='r', facecolor='none')
ax2.add_patch(rect)