How to separate horizontly on the basis of gaps or space
1 次查看(过去 30 天)
显示 更早的评论
Hello friends,
I am trying to separate all characters vertically separated through gaps/spaces as highlighted in image through red, blue and green color
If I am trying to use bwlabel, it is separating connected components. thus I am losing ligatures and dots. Any help by providing me the link or sample code shall be highly appreciated.
Regards
回答(1 个)
Image Analyst
2013-11-6
For this simple case, I'd just get profiles. I would sum the image horizontally and vertically and look for spikes.
horizontalProfile = sum(grayImage, 1); % Sum across all rows.
verticalProfile = sum(grayImage, 2); % Sum across all columns.
But for more sophisticated algorithms, you'll need to check the OCR literature: http://iris.usc.edu/Vision-Notes/bibliography/contentschar.html#OCR,%20Document%20Analysis%20and%20Character%20Recognition%20Systems
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Language Support 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!