This project demonstrates real-time drone detection using YOLOv5 and OpenCV. It detects drones in real-time and displays a warning when a drone is detected inside or near a defined rectangle.
- Real-time drone detection using YOLOv5 with detection coordinates and confidence percentage.
- No Code: Interactive and dynamic detection boundary creation and adjustment.
- A warning message is displayed when a drone is detected inside or near the set boundary.
- Clone the repository:
- git clone https://github.com/Ayushkumawat/Advanced-Aerial-Drone-Detection-System
- Inside your project directory, create a virtual environment
- python -m venv venv
- Activate the virtual environment
- .\venv\Scripts\activate
- Install the required Python libraries:
- pip install -m requirements.txt
- Run the script:
- python Advanced_Drone_Detection.py
-
Enhanced Security Real-time detection of drones for improved security in airports, public events, and restricted areas.
-
Automated Monitoring Reduce manual surveillance by automating the drone detection process using computer vision and machine learning.
-
Customizable and Interactive Define and adjust the detection area using an interactive rectangle for accurate and adaptable detection.
-
Real-time Feedback Instant detection and warning messages provide immediate responses to potential drone threats.
-
Open-source and Extendable You can access the open-source codebase for customization and integration into existing security systems.
-
Scalable and Cost-effective Efficient utilization of resources with a balance of accuracy and performance, resulting in cost savings.
The Drone Detection model was trained on a diverse dataset consisting of 1400 images of different types of drones. The dataset was carefully curated and labeled to ensure accurate annotations. It covers a wide range of drone variations, sizes, orientations, and backgrounds.
The dataset was prepared using the Roboflow platform and exported through its API. This streamlined the dataset preparation process and ensured high-quality data inputs for training the model.
The availability of this diverse and well-annotated dataset enables the Drone Detection model to learn from a wide range of drone images, resulting in improved accuracy and reliability in real-world detection scenarios.
The dataset used in this project can be downloaded from here.
The script will open a live video feed from the default camera.
- To create a rectangle, click and drag the mouse on the video feed to define the four corners of the rectangle.
- The rectangle can be adjusted by dragging the corners.
- A warning message will be displayed whenever a drone is detected inside or near the rectangle.
- Press 'q' to quit the program.
- You can modify the
classes
list in the code to include or exclude specific classes of objects for detection. - Adjust the confidence threshold (
conf
) to control the sensitivity of detection. - Experiment with different YOLOv5 model sizes for performance and accuracy trade-offs.