Detection of drones using their thermal signatures from thermal camera through YOLO-V3 based CNN with modifications to encapsulate drone motion

Overview

Drone Detection using Thermal Signature

This repository highlights the work for night-time drone detection using a using an Optris PI Lightweight thermal camera. The work is published in the International Conference of Unmanned Air Systems 2021 (ICUAS 2021) and the paper can be read in detail in ICUAS_2021_paper.

Requirements

The following are the requirements with Python 3.7.7

tensorflow==2.4.0
opencv_contrib_python==4.5.1.48
numpy==1.20.3	

Model Architecture

The following diagram highlights the architecture of model based on YOLOV3. However, unlike typical single image object detection, the model takes in the concatenation of a specified number of images in the past relative to the image of interest. This is to encapsulate the motion of the drone as an input feature for detection, a necessity given that thermal signatures of different are generally globular in shape after a certain distance depending on the fidelity of the thermal camera used. Further details can be found in ICUAS_2021_paper.

Model Architecture

Training and Testing

Clone the repository, adjust the training/testing parameters in train.py as shown and execute the code. The training data comprises of data from a controlled indoor environment while the test data contains a mixture data from indoor and outdoor environments.

# Train options
TRAIN_SAVE_BEST_ONLY        = True # saves only best model according validation loss (True recommended)
TRAIN_CLASSES               = "thermographic_data/classes.txt"
TRAIN_NUM_OF_CLASSES        = len(read_class_names(TRAIN_CLASSES))
TRAIN_MODEL_NAME            = "model_2"
TRAIN_ANNOT_PATH            = "thermographic_data/train" 
TRAIN_LOGDIR                = "log" + '/' + TRAIN_MODEL_NAME
TRAIN_CHECKPOINTS_FOLDER    = "checkpoints" + '/' + TRAIN_MODEL_NAME
TRAIN_BATCH_SIZE            = 4
TRAIN_INPUT_SIZE            = 416
TRAIN_FROM_CHECKPOINT       = False # "checkpoints/yolov3_custom"
TRAIN_LR_INIT               = 1e-4
TRAIN_LR_END                = 1e-6
TRAIN_WARMUP_EPOCHS         = 1
TRAIN_EPOCHS                = 10
TRAIN_DECAY                 = 0.8
TRAIN_DECAY_STEPS           = 50.0

# TEST options
TEST_ANNOT_PATH             = "thermographic_data/validate"
TEST_BATCH_SIZE             = 4
TEST_INPUT_SIZE             = 416
TEST_SCORE_THRESHOLD        = 0.3
TEST_IOU_THRESHOLD          = 0.45

Once the model is trained, you can test the model's predictions on images using detect_image.py. Adjust the the following parameters in detect_image.py and execute the code.

CLASSES               = "thermographic_data/classes.txt"
NUM_OF_CLASSES        = len(read_class_names(CLASSES))
MODEL_NAME            = "model_2"
CHECKPOINTS_FOLDER    = "checkpoints" + "/" + MODEL_NAME
ANNOT_PATH            = "thermographic_data/test/images/pr"
OUTPUT_PATH           = 'predicted_images/' + MODEL_NAME + "/pr"
DETECT_BATCH          = False
DETECT_WHOLE_VID      = True
BATCH_SIZE            = 1804
IMAGE_PATH            = ANNOT_PATH + "/free_3/free_3_frame_100"
INPUT_SIZE            = 416
SCORE_THRESHOLD       = 0.8
IOU_THRESHOLD         = 0.45

Similarly, you can test the model's predictions on videos using detect_video.py. Adjust the following parameters in detect_video.py and execute the code.

CLASSES               = "thermographic_data/classes.txt"
NUM_OF_CLASSES        = len(read_class_names(CLASSES))
MODEL_NAME            = "model_2"
CHECKPOINTS_FOLDER    = "checkpoints" + "/" + MODEL_NAME
ANNOT_PATH            = "raw_videos/free_2.mp4"
OUTPUT_PATH           = 'predicted_videos/' + MODEL_NAME 
INPUT_SIZE            = 416
SCORE_THRESHOLD       = 0.8
IOU_THRESHOLD         = 0.45

Examples of predictions

An example of correct drone detection in indoor environment shown below.

Indoor Detection

An example of correct drone detection in outdoor environment shown below.

Outdoor Prediction

Video of model predictions shown in indoor environment can be found here.

You might also like...
This is a model to classify Vietnamese sign language using Motion history image (MHI) algorithm and CNN.
This is a model to classify Vietnamese sign language using Motion history image (MHI) algorithm and CNN.

Vietnamese sign lagnuage recognition using MHI and CNN This is a model to classify Vietnamese sign language using Motion history image (MHI) algorithm

A PaddlePaddle implementation of STGCN with a few modifications in the model architecture in order to forecast traffic jam.
A PaddlePaddle implementation of STGCN with a few modifications in the model architecture in order to forecast traffic jam.

About This repository contains the code of a PaddlePaddle implementation of STGCN based on the paper Spatio-Temporal Graph Convolutional Networks: A D

This is a Keras implementation of a CNN for estimating age, gender and mask from a camera.

face-detector-age-gender This is a Keras implementation of a CNN for estimating age, gender and mask from a camera. Before run face detector app, expr

Camera-caps - Examine the camera capabilities for V4l2 cameras
Camera-caps - Examine the camera capabilities for V4l2 cameras

camera-caps This is a graphical user interface over the v4l2-ctl command line to

Based on Yolo's low-power, ultra-lightweight universal target detection algorithm, the parameter is only 250k, and the speed of the smart phone mobile terminal can reach ~300fps+
Based on Yolo's low-power, ultra-lightweight universal target detection algorithm, the parameter is only 250k, and the speed of the smart phone mobile terminal can reach ~300fps+

Based on Yolo's low-power, ultra-lightweight universal target detection algorithm, the parameter is only 250k, and the speed of the smart phone mobile terminal can reach ~300fps+

The code uses SegFormer for Semantic Segmentation on Drone Dataset.
The code uses SegFormer for Semantic Segmentation on Drone Dataset.

SegFormer_Segmentation The code uses SegFormer for Semantic Segmentation on Drone Dataset. The details for the SegFormer can be obtained from the foll

Tello Drone Trajectory Tracking

With this library you can track the trajectory of your tello drone or swarm of drones in real time.

Vehicle Detection Using Deep Learning and YOLO Algorithm
Vehicle Detection Using Deep Learning and YOLO Algorithm

VehicleDetection Vehicle Detection Using Deep Learning and YOLO Algorithm Dataset take or find vehicle images for create a special dataset for fine-tu

Object detection using yolo-tiny model and opencv used as backend
Object detection using yolo-tiny model and opencv used as backend

Object detection Algorithm used : Yolo algorithm Backend : opencv Library required: opencv = 4.5.4-dev' Quick Overview about structure 1) main.py Load

Owner
Chong Yu Quan
Chong Yu Quan
Drone Task1 - Drone Task1 With Python

Drone_Task1 Matching Results 3.mp4 1.mp4

MLV Lab (Machine Learning and Vision Lab at Korea University) 11 Nov 14, 2022
Yolo object detection - Yolo object detection with python

How to run download required files make build_image make download Docker versio

null 3 Jan 26, 2022
Convert Mission Planner (ArduCopter) Waypoint Missions to Litchi CSV Format to execute on DJI Drones

Mission Planner to Litchi Convert Mission Planner (ArduCopter) Waypoint Surveys to Litchi CSV Format to execute on DJI Drones Litchi doesn't support S

Yaros 24 Dec 9, 2022
LF-YOLO (Lighter and Faster YOLO) is used to detect defect of X-ray weld image.

This project is based on ultralytics/yolov3. LF-YOLO (Lighter and Faster YOLO) is used to detect defect of X-ray weld image. Download $ git clone http

null 26 Dec 13, 2022
Yolo ros - YOLO-ROS for HUAWEI ATLAS200

YOLO-ROS YOLO-ROS for NVIDIA YOLO-ROS for HUAWEI ATLAS200, please checkout for b

ChrisLiu 5 Oct 18, 2022
TPH-YOLOv5: Improved YOLOv5 Based on Transformer Prediction Head for Object Detection on Drone-Captured Scenarios

TPH-YOLOv5 This repo is the implementation of "TPH-YOLOv5: Improved YOLOv5 Based on Transformer Prediction Head for Object Detection on Drone-Captured

cv516Buaa 439 Dec 22, 2022
Drone detection using YOLOv5

This drone detection system uses YOLOv5 which is a family of object detection architectures and we have trained the model on Drone Dataset. Overview I

Tushar Sarkar 27 Dec 20, 2022
Using this codebase as a tool for my own research. Making some modifications to the original repo for my own purposes.

For SwapNet Create a list.txt file containing all the images to process. This can be done with the GNU find command: find path/to/input/folder -name '

Andrew Jong 2 Nov 10, 2021
NFT-Price-Prediction-CNN - Using visual feature extraction, prices of NFTs are predicted via CNN (Alexnet and Resnet) architectures.

NFT-Price-Prediction-CNN - Using visual feature extraction, prices of NFTs are predicted via CNN (Alexnet and Resnet) architectures.

null 5 Nov 3, 2022
Drone-based Joint Density Map Estimation, Localization and Tracking with Space-Time Multi-Scale Attention Network

DroneCrowd Paper Detection, Tracking, and Counting Meets Drones in Crowds: A Benchmark. Introduction This paper proposes a space-time multi-scale atte

VisDrone 98 Nov 16, 2022