How to detect Hotspots in an image

做~自己de王妃 提交于 2019-11-29 08:54:40

问题


How to detect a hotspot in an image using opencv? I have tried googling but couldnt get a clue of it.

Description: I need to filter good images from a live video stream. In this case I need to just detect the Hotspot in a frame. I need to do this in opencv.

What is HotSpot?

Hot spots are shiny areas on a subject’s face which are caused by a flash reflecting off a shiny surface or by uneven lighting. It tends to make the subject look as if they are sweating, which is not a good look.

Update : http://answers.opencv.org/question/7223/hotspots-in-an-image/ http://en.wikipedia.org/wiki/Specular_highlight

The above two links also could help for my Post?

Image with HotSpot:

Image Without HotSpot:


回答1:


An automatic rough indication of these "hotspot" areas can be obtained by a gaussian filtering followed by a binarization. The expectation is that the "hotspot" is much brighter than the area around it, so after a gaussian filtering they will be at least slightly highlighted and, at the same time, image artifacts are reduced due to the nature of the low-pass filtering.

Example results follow. Binarization at 0.75 (range is always [0, 1]) after a simple conversion to grayscale, Binarization at 0.85 after a gaussian filtering in the B channel of the HSB colorspace:

In both cases large components were removed due to the assumption that "hotspots" aren't too big.



来源:https://stackoverflow.com/questions/14809506/how-to-detect-hotspots-in-an-image

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!