This project leverages the YOLOv4-Tiny algorithm to perform real-time object detection and classification for Unmanned Autonomous Vehicles (UAVs). It detects and saves snapshots of identified objects as the UAV navigates its environment.
It detects the following shapes: Circle, Target, Triangle, Square
- Runs completely on on-board computer of UAV
- Yolo-V4 Tiny model is optimised to give 20 fps on used hardware.
- On detecting objects of interest, the model automatically saves the snapshot of the frame in local directory along with time stamp and GPS coordiantes.
- Provides full control over Traversal of the drone both Manually (using keyboard) and Autonomously.
- Raspberry Pi 5
- Waveshare OV5640 USB Camera
- Pixhawk 2.4.8
- GPS Module
Git clone the repository into a folder
-
git clone https://github.com/AFC-IIITDMJ/Aerothon-24.git
Navigate to this folder in a new terminal
-
cd Aerothon-24
It is recommended that you create a python virtual environment and install the required libraries using the requirements file
-
pip install -r requirements.txt
Running this file will arm the UAV and take off to an altitude of 15 meters, hold position for 5 seconds, and then execute an RTL (Return to Launch) command to land.
-
python pulse.py
Running this file will arm the UAV, take off to an altitude of 15 meters, and navigate to each set of coordinates listed in the ground_coordinate.txt file, holding position for 1.5 seconds at each GPS point. To modify the traversal path, edit the coordinates in the ground_coordinate.txt file.
-
To edit coordiantes for traversal
sudo nano gound_coordinate.txt
-
To run Traversal file
python traversal.py
Running this file will start YoloV4-Tiny detection on /dev/ttmACM0 port. You can also enter custom Connection String in Drone class.
-
python only_detection.py
Running this file will arm the UAV and take off to an altitude of 15 meters, hold position for 5 seconds, and then execute an RTL (Return to Launch) command to land.
-
python detection_traversal.py
Running this file will arm the UAV and take off to an altitude of 15 meters, hold position for 5 seconds, and then use commands from keyboard to run traverse. Up arrow key moves it forward and so on. All commands are executed for duration of 1 second.
-
python keyboard.py