Line prob at o2
Show older comments
image2= o2{120}
1 Comment
Cris LaPierre
on 23 Nov 2021
original question
Can anyone help me to understand in the line 5 why it is using 136?
i2 = imread('00020361.bmp');
m2 = i2(201:808,201:808);
n2 = imbinarize(m2,0.6);
o2 = mat2cell(n2,[32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32],[32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32]);
image2= o2{136}
c = normxcorr2(image1,image2);
figure, surf(c), shading flat
[ypeak, xpeak] = find(c==max(c(:)));
yoffSet = ypeak-size(image1,1);
xoffSet = xpeak-size(image2,2);
figure
imshow(image2);
imrect(gca, [xoffSet+1, yoffSet+1, size(image1,2),size(image1,1)]);
Accepted Answer
More Answers (0)
Categories
Find more on Image Processing Toolbox in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!