How to separate horizontly on the basis of gaps or space
1 view (last 30 days)
Show older comments
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 Comment
Answers (1)
Image Analyst
on 6 Nov 2013
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 Comments
See Also
Categories
Find more on Language Support 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!