1.完整项目描述和程序获取
>面包多安全交易平台:https://mbd.pub/o/bread/ZJWUlp9s
>如果链接失效,可以直接打开本站店铺搜索相关店铺:
>如果链接失效,程序调试报错或者项目合作也可以加微信或者QQ联系。
2.部分仿真图预览
3.算法概述
自然场景下的文本检测是自然场景图像信息提取的基础,在车牌识别、实时翻译、图像检索等领域具有广泛的应用价值及研究意义。基于连通区域的方法是自然场景文本检测中最为常见的方法,其中最大稳定极值区域(Maximally Stable Extremal Regions,MSER)算法和颜色聚类算法都有着广泛的应用。
4.部分源码
...........................................................................
[x,y]=size(bwimg);
j=1;
cwidth=[];
whole=x*y;
connComp = bwconncomp(bwimg); % Find connected components
threefeature = regionprops(connComp,'Area','BoundingBox','Centroid' );
broder=[threefeature.BoundingBox];%[x y width height]字符的区域
area=[threefeature.Area];%区域面积
centre=[threefeature.Centroid];
%area
for i=1:connComp.NumObjects
leftx=broder((i-1)*4+1);
lefty=broder((i-1)*4+2);
width=broder((i-1)*4+3);
height=broder((i-1)*4+4);
cenx=floor(centre((i-1)*2+1));
ceny=floor(centre((i-1)*2+2));
if area(i)<10||area(i)>0.3*whole
%display(area(i));
bwimg(connComp.PixelIdxList{i})=0;
elseif width/height<0.1||width/height>2
%display(width),display(height);
bwimg(connComp.PixelIdxList{i})=0;
else
cwidth=[cwidth,width];
rectangle('Position',[leftx,lefty,width,height], 'EdgeColor','g','LineWidth',1);
seg_img_color{j}=colorImg(lefty+1:lefty+height,leftx+1:leftx+width,:); % +1 避免索引为0
seg_img_bw{j}=p_img(lefty+1:lefty+height,leftx+1:leftx+width);
j=j+1;
end
end
p_image=bwimg;
A364