How can I match a small part of an image to its whole image?

조회 수: 4 (최근 30일)
Neo
Neo 2015년 7월 7일
댓글: sonia khan 2015년 10월 4일
Let's say I have an image of a flower, I cut out 3 seemingly identical smaller images of petals from that flower. Now without simply looking at the image and putting those petals back in their EXACT locations, how can I know where each petal belongs EXACTLY in that image of the flower? I thought about doing histogram analysis of each individual petal's image then matching it back to original image, but I am not sure if the histogram of an image can show differences between very similar images. Is this a good method? Is there a better method? Thanks Mates!

채택된 답변

Image Analyst
Image Analyst 2015년 7월 7일
No, that histogram algorithm won't work at all, as you'll realize if you just give it a little thought. What you want to use is normalized cross correlation, which is done by the function normxcorr2() in the Image Processing Toolbox. I'm attaching my demo of it, below this image that it creates.
  댓글 수: 22
Neo
Neo 2015년 8월 3일
Ah. I see thanks Analyst.
sonia khan
sonia khan 2015년 10월 4일
salam can u plz give me the code of this

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Image Segmentation and Analysis에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by