Rewrite normalization algorithm.

This is a major revision that removes the `method` parameter of `match_template` and uses a new normalization method.

Note that the example result is different with this new normalization.
This commit is contained in:
Tony S Yu
2012-05-08 21:32:07 -04:00
parent 753e999a7a
commit 5682d27eb0
4 changed files with 72 additions and 78 deletions
+1 -2
View File
@@ -29,8 +29,7 @@ for x, y in target_positions:
image[x:x+size, y:y+size] = target
image += randn(400, 400)*2
# Match the template.
result = match_template(image, target, method='norm-corr')
result = match_template(image, target)
found_positions = peak_local_max(result)