I have a set of Pokemon sprites (example) and an image where one of these sprite is shown.
an image contains a sprite
I am planning to find the best match result among sprites with res = cv2.matchTemplate
so that the name of that Pokemon can be obtained.
for t in templates:
res = cv2.matchTemplate(img, t, cv2.TM_CCOEFF_NORMED)
min_val, max_val, min_loc, max_loc = cv2.minMaxLoc(res)
However, I don't know how to pick the best result with the res
. How to use res
as a metric to evaluate the match? Thank you!