error in detecting components using bwlabel

2 次查看(过去 30 天)
I used bwlabel for detecting connected components but i got error output i.e 3 objects are detected instead of 8. I am attaching input image. Expecting your suggestion.

采纳的回答

Walter Roberson
Walter Roberson 2018-1-29
bwlabel assumes that the white pixels are where the data is and that the black pixels are holes. When you have black text on a white background you need to invert the image.
  4 个评论
Image Analyst
Image Analyst 2018-1-30
Or you could sum the image vertically to find the gaps between the symbols.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Get Started with Image Processing Toolbox 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by