separating foreground from background and working on the masked image in matlab

2 次查看(过去 30 天)
Hi,
This question is haunting me for a long time. first I was working in color so I have asked people here. now i am working on grey levels, but still this question is not resolved. I am reading an image using imread function then converting the whole image to grey levels, then I have to work only on the grey levels of the foreground, the code should not include the background, could anyone suggest a code to insert in my code please....i will attach a sample image as well ...
  18 个评论
Malini Bakthavatchalam
Thank you for the reply. I understand the concept you explained for the background removal. its working in my code, but if I have images with background other than whites i cannot use this alogrithm right ?
like i am attaching a sample image
Sindar
Sindar 2020-10-2
编辑:Sindar 2020-10-2
This segmenter algorithm will likely fail, but you may be able to build a new algorithm in the Image Segmenter app (or Color Thresholder app). It really depends on the diversity of your images. For example, I'd expect 6.jpg to be almost trivial to segment, whereas 10.jpg and 25.jpg are probably doable but trickier, and creating a single algorithm that works on all three could be difficult.
(everything else in the code will function the same)

请先登录,再进行评论。

回答(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