Fire detection Colour range
I am trying to use cv2.in Range() function to extract fire from an image.Although results are not that promising. Range I am using is lower = [18,255,255],upper = [35,255,255]. Can you please provide which range will give better results with lesser False positives.
Thanks
Try to convert the image to another color space, like HSV.
Other idea: it seems that the image is overexposed, as the red and green channels are saturated. Try to underexpose the image, so the fire is in the mid tones, and the rest is dark. It will probably give better results.
You can also make an interactive segmentation algorithm with 6 trackbars (the 3 min and 3 max values), so you can experiment the best parameters for a given image.
(and if you post an example image, we'll be able to give even better suggestions.)
Please attach an example of the fire image?