Question concerning color segmentation performance.

조회 수: 2 (최근 30일)
Cosmic Clarity
Cosmic Clarity 2014년 9월 6일
댓글: Cosmic Clarity 2014년 9월 8일
Hello there!
I am looking to perform color segmentation on specific images in order to isolate the green objects in the image (more specifically, a green glove). I have this part covered, with all credit going to Image Analyst, whose Simple Color Detection code is the basis of the program, which is attached. However, I've encountered a problem where, in very similar circumstances, I successfully isolate the green in one image, while I am unable to detect any green at all in the other. I am using the same thresholds all throughout.
Specifically, said successful image is here:
While unsuccessful image is here:
Can anyone please explain why this happens? Is it simply a matter of adjusting the thresholds ever so slightly, or is there something I am missing here?
And if possible, is there a way for me to improve the performance and robustness of this color segmentation method?
Thank you for your time. Any help would be greatly appreciated.

채택된 답변

Image Analyst
Image Analyst 2014년 9월 6일
Probably. My demo code (attached below here) gives you the histograms of the h, s, and v channels. You need to see where green lies. It's probably around 0.2-0.4 or so You might have to combine it with other color channels. For example since everything else is some shade of gray, you might be able to threshold on the saturation channel. Attach your two images (working and not working) if you want more help.
  댓글 수: 4
Image Analyst
Image Analyst 2014년 9월 8일
So now that you've had a chance to try it, what do you think? Good enough to accept the answer, or not?
Cosmic Clarity
Cosmic Clarity 2014년 9월 8일
You've suggested a lot of ways to improve the program, and these codes will help immensely in optimizing the color segmentation. This is more than enough. Thank you for the help.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

Community Treasure Hunt

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

Start Hunting!

Translated by