Effacer les filtres
Effacer les filtres

Will normxcorr2 be helpful in comparing 2 images with little differences.?

2 vues (au cours des 30 derniers jours)
Ankit Gupta
Ankit Gupta le 8 Mai 2013
Hi , I have 2 images, one in which a circular loop been placed on a rectangular surface, second is of the same circular loop at different position(difference in mm) on the same rectangular surface. will normxcorr2 be helpful in detecting the object shift in an image, or if there is any other way to detect the shift in the object in image automatically, as I have to deal with huge database of those images and detect how much the loop is been shifted.

Réponses (1)

Image Analyst
Image Analyst le 8 Mai 2013
That should work, as long as it is the same loop, and not distorted or misshapen.
  2 commentaires
Ankit Gupta
Ankit Gupta le 8 Mai 2013
I tried to use this and ran this code:( the images are in gray)
cc = normxcorr2(imrgb_z{1},imrgb_z{250});
[max_cc, imax] = max(abs(cc(:)));
[ypeak, xpeak] = ind2sub(size(cc),imax(1))
corr_offset = [ (ypeak-size(imrgb_z{1},1)) (xpeak-size(imrgb_z{1},2)) ]
I am getting the result as
corr_offset =
0 0
What does that means, is there a no difference in the images? But actually there is if i see it manually.
Anand
Anand le 9 Mai 2013
Could you upload a couple of sample images...

Connectez-vous pour commenter.

Community Treasure Hunt

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

Start Hunting!

Translated by