https://github.com/tugcantopaloglu/hazmat-detection-image-processing
A hazmat symbol detection with ready to use in ros simulation and real time turtlebot robots.
https://github.com/tugcantopaloglu/hazmat-detection-image-processing
barrel hazmat image-processing robotics ros
Last synced: 2 months ago
JSON representation
A hazmat symbol detection with ready to use in ros simulation and real time turtlebot robots.
- Host: GitHub
- URL: https://github.com/tugcantopaloglu/hazmat-detection-image-processing
- Owner: tugcantopaloglu
- License: mit
- Created: 2025-06-30T11:40:41.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-06-30T11:44:16.000Z (12 months ago)
- Last Synced: 2025-06-30T12:39:14.798Z (12 months ago)
- Topics: barrel, hazmat, image-processing, robotics, ros
- Language: Python
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Hazardous‑Material Sign & Barrel Detection in a Robotic Environment
This project uses **OpenCV** with the **SIFT** algorithm to detect hazardous‑material symbols (hazmat signs) and coloured barrels (red / blue) in a video file. There is no YOLO or any framework like that. Only pure image processing.
---
## Requirements
- Python 3.x
- OpenCV → `opencv-contrib-python`
- NumPy
Install dependencies:
```bash
pip install -r requirements.txt
```
---
## Folder Structure
```
main.py
video.mp4
detections/ # Frames with detections will be saved here
hazmats/ # Template PNG files (hazmat symbols)
```
---
## Usage
1. Place PNG templates of the hazmat signs you want to detect inside the `hazmats/` folder.
2. Put the video you want to analyse in the project root as `video.mp4`.
3. Run the script:
```bash
python main.py
```
4. When prompted, enter the frame interval (e.g. **20**) or press *Enter* to accept the default (recommended) value.
5. Detected objects are shown on‑screen and saved to the `detections/` folder.
Press any key to continue after each displayed detection.
*(If the folder does not exist, nothing is saved.)*
---
## Notes
- A screenshot is taken for every detected object and written to `detections/`.
- Red and blue barrels are detected via colour‑based segmentation.
- Hazmat symbols are detected using **SIFT** keypoint matching and template matching.