g1=imread('eleve.jpg');imshow(a);h=fspecial('average', 9);g=imfilter(a,h,'replicate');g=im2bw(g1,0.5); imshow(g);B=boundaries(g);d=cellfun('length', B);[max_d,k]=max(d);b=B{1};[M N]=size(g);g=bound2im(b,M,N,min(b(:,1)),min(b(:,2)));imshow(g);[s,su]=bsubsamp(b,50);g2=bound2im(s,M,N,min(s(:,1)),min(s(:,2)));imshow(g2); cn=connectpoly(s(:,1),s(:,2));g2=bound2im(cn,M,N,min(cn(:,1)),min(cn(:,2)));imshow(g2);c=fchcode(su);c.fccError using ==> bound2im at 61The shifted boundary is outside the M-by-N region.Error in ==> FreemanCC at 18g2=bound2im(s,M,N,min(s(:,1)),min(s(:,2)));
MATLAB: Hello ! its urgent cananyone please help me with this error in the MATLAB Code
code de fremanImage Processing Toolbox
Best Answer