An AI-based fire detection system built entirely in a Google Colab notebook. It uses the YOLOv8 object detection model to identify fire in real-time from a webcam or video input. The system is lightweight, easy to set up, and can be extended with thermal filtering and IoT device integration.
- π Real-time fire detection using webcam or video
- π€ Fine-tuned YOLOv8 model on fire datasets
- can detect invisible flames
- βοΈ Runs entirely on Google Colab (no setup needed!)
- πΈ Supports webcam access using Colab + JavaScript hack
- π Logs fire detection and can be extended with alert systems
- π§ Future-ready for thermal-style filtering and ESP32 integration
- Python
- YOLOv8 (Ultralytics)
- OpenCV β for real-time video processing
- Google Colab β GPU-powered training and testing
- (Planned) ESP32 + GPIO alert system
-
Open the notebook:
π [Click here to open the Fire Detection Notebook] -
Follow the cells step-by-step:
- Install dependencies
- Train or load YOLOv8 model
- Upload a video or enable webcam
- Run detection loop
-
Webcam Access (optional):
You can use JavaScript in Colab to access your webcam like this:from IPython.display import display, Javascript display(Javascript('''navigator.mediaDevices.getUserMedia({ video: true })'''))