Extracting bright spots on image

10 ビュー (過去 30 日間)
Mehran Varshosaz
Mehran Varshosaz 2022 年 7 月 7 日
コメント済み: Image Analyst 2022 年 7 月 8 日
Does any of you can help me on finding bright spots on an image?
We have a traffic light and the problem is that we have to extract the exact coordinates of each led of traffic light. Check the attached photo.
One idea is that to somehow binerize the image so that the pixels with high intensity get a value of 1 and others get 0. Then using the bwconncomp function we can find the coordinates of each led.
The problem is that binearizing the image doesn't always return good results. One example of binerizing the attached image is also included.
Any idea on how to binerize image so that the effect of light from the adjacent leds is removed?

採用された回答

Steve Eddins
Steve Eddins 2022 年 7 月 8 日
Try something like the following:
  1. Convert to grayscale (using rgb2gray).
  2. Use imextendedmax to pick out the bright peaks. You'll need to experiment to find an appropriate H value. To do that, look at how much brighter the LED peaks are compared to their immediate surroundings.
  3. Use a morphological opening (imopen) with a small disk for additional spot separation and cleanup.
  1 件のコメント
Image Analyst
Image Analyst 2022 年 7 月 8 日
imtophat would also be worth a try.

サインインしてコメントする。

その他の回答 (0 件)

製品


リリース

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by