Setting an adaptive threshold for image binarization

4 views (last 30 days)
Hello everyone.
Does any of you have any idea on how to set an adaptive threshold on images similar to ones I have attached below in order to binarize the image so that the luminous LED become 1 and other pixels in the background become 0?
I have tried adaptive thresholding and Otsu thresholding techniques but non of them returned reliable results.
I do not expect to extactly extract all luminous LEDs from image but at least 80% of them must be found.
By the way, I also use watershed segmentation after binarizing the image, so if 2-3 LEDs are connected together after binarization, it's not a big deal :)
Any Method other than thesholding for finding the position of LEDs is also appreciated.

Answers (0)

Community Treasure Hunt

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

Start Hunting!