Image Processing - normxcorr2 (xpeak)

1 view (last 30 days)
KhooSzeWei
KhooSzeWei on 8 Nov 2013
Greetings. I'm using the following codes to detect the movement of the speckles during a tensile testing. The codes provide an accurate result in the beginning. However, I've found out that the determined offset values are no longer acceptable and this is due to the xpeak started to provide ridiculous values. Therefore, can someone here kindly explain to me what going on with the xpeak value? Why does it looks ok in the beginning and turns unacceptable after correlating a few pairs of images? Thanks!!!
c = normxcorr2(sub_deformed,sub_undeformed); figure, surf(c), shading flat
[max_c, imax] = max(abs(c(:))) [ypeak, xpeak] = ind2sub(size(c),imax(1)) corr_offset = [(xpeak-size(sub_deformed,2)) (ypeak-size(sub_deformed,1))]
rect_offset = [(rect_undeformed(1)-rect_deformed(1)) (rect_undeformed(2)-rect_deformed(2))]
offset = corr_offset + rect_offset; xoffset = offset(1); yoffset = offset(2);

Answers (0)

Community Treasure Hunt

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

Start Hunting!