Visual fire detection
May 22 we had a second sensor test flight. With this flight, we could test the improved payload modules and this time we did get usable images from the downwards facing camera. With these images we could try out some visual fire detection algorithms.
The first algorithm simply filters by color.
The color filter will result in many false positives and we will never be able to trust on color alone.
The second algorithm tries to find flickering pixels: pixel values that go up and down over time. The camera recorded images in bursts of 8 images, here is such a burst of a very small fire:
When we check for flicker and threshold the results, we get:
The flicker detection also has many false positives. This is possibly caused by the motion of the plane, resulting in movement of pixels over the image. The moved pixel can be replaced by a pixel that has very different values. If this happens more often over the burst, it will be seen as a flickering pixel.
To be able to compensate for the movement, we need to calculate the optic flow. We followed the algorithm as described in Real-Time Quantized Optical Flow. This resulted in very noisy flow fields, which was caused by lack of texture in certain parts of the images. We filtered out those flow vectors by checking the difference of the possible displacements. If the difference is large enough, we assumed one displacement matched a lot better than the others and thus there must be enough texture. The result is shown in the image below.
There is still some noise in the flow vectors, especially if the exposure time of the camera suddenly changes. However, once the exposure is under control, the noise will be low enough to use the optic flow to compensate and maybe even find moving smoke or fire.
In the images below you can see results when we compensated for average motion.
There are still more features that we can extract from the images, so far the results are promising and we trust that we can detect fire with the color camera.
blog comments powered by Disqus