フィルターのクリア

How can I confirm that a template image is found in the primary image using cross correlation?

5 ビュー (過去 30 日間)
How can I really confirm that the small template image exists in another image using the cross correlation? and please which is better for template matching between normxcorr2() and xcorr2() methods?
I am working on fingerprint matching and it is required that around each minutiae point i extract a template image of a specified size. and this template image will be searched for in a different supplied fingerprint image. My understanding of correlation is that it gives the level of similarity between two signals such as images, so is there like a threshold level that if the similarity level crosses then surely the template image is in the primary image or how do I know that the template is found in the primary image?
Thanks.
  2 件のコメント
Adam Danz
Adam Danz 2020 年 3 月 16 日
@Fego Etese, I saw your msg from a different thread pointing me to this one. It looks like Image Analyst has you straightened out.
Fego Etese
Fego Etese 2020 年 3 月 21 日
@Adam Danz thanks so much for your help also, Image Analyst helped me with this question.

サインインしてコメントする。

採用された回答

Image Analyst
Image Analyst 2020 年 3 月 11 日
Threshold the correlation output image. If the signal is high enough, then you can assume the pattern is there. If there are no points above the threshold, then the pattern is not there. If you still need help, then attach your template image, an image where the template appears, and an image where the template does not appear.
  5 件のコメント
Fego Etese
Fego Etese 2020 年 3 月 14 日
Thanks Image Analyst. I appreciate your help. I've seen that normalized cross correlation outputs values between 1 and -1 so i can use about 0.8 to determine whether the template image is within the primary image.
But please one more question on this, sorry to bother you more. If there are two areas with the same correlation value or maybe two areas above the threshold point how do i select the one that is the correct area?
Thanks once again.
Image Analyst
Image Analyst 2020 年 3 月 15 日
It's possible to have the same correlation value with different templates. In that case, you might want to subtract the template from the image at that location, maybe with imabsdiff(), and determine which had the lower average absolute difference.

サインインしてコメントする。

その他の回答 (1 件)

Satadru Mukherjee
Satadru Mukherjee 2021 年 4 月 27 日
Please refer this video --
Happy Learning :-)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by