GithubHelp home page GithubHelp logo

coolpoor / objectdetection Goto Github PK

View Code? Open in Web Editor NEW

This project forked from littlepieces/objectdetection

0.0 0.0 0.0 1.64 MB

infrared small and dim target detection

Python 96.06% MATLAB 0.22% C++ 3.72%

objectdetection's Introduction

Infrared Small and Dim Target Detection

Our implements contain two parts : SDDNet and IC-Module.
SDDNet: Small and Dim Object Detection. Using segmentation pictures as the labels.
IC-Module: Inter-frame correlation Module. Using the inter-frame correlation information aim to reduce the false alarm rate.

Environments

pytorch==1.3.0

torchvision==0.5.0

python==3.7

visdom

torch2trt (refer to :https://github.com/NVIDIA-AI-IOT/torch2trt)

Inference

To run inference, you can type the following commands:

python SDD_test.py  --data_path (image to inference)  --load_model  (trained model)   
python IC_test.py  --data_path (image to inference)  --load_model  (trained model)    

And the result will be saved in test_result/SDD or test_result/IC folder if not specified.

More parameters:

  --save_path : path to save result.
  --acc : if True, use tensorRT to accelerate inference.

Training

DDP mode is adopted in both SDDNet and IC-Module, and 4 Gpus are used for training.

To run training scripts, you can type the following commands:

python -m torch.distributed.launch --nproc_per_node 4 SDD_train.py --data_path  (training dataset path)  --label_path (label path) & nohup visdom    
python -m torch.distributed.launch --nproc_per_node 4 IC_train.py --data_path  (training dataset path)  --label_path (label path) & nohup visdom  

And the trained model will be saved in sdd_checkpoints or ic_checkpoints folder if not specified.

More Parameters:

  --save_path : path to save checkpoints.
  --vis : whether to visualize, default True. 
  --load_model : path to load pre-trained model.

Others(in scripts folder)

  1. If you want to train the model with your own custom dataset, you should prepare binarized segmentation as the label. We provide the script binary.py to convert images to binarized images.

  2. We provide a script DataAug.py to enhance prepared dataset before training, the default folders where storing the training data and labels are ‘train’ and ‘label’ respectively.

  3. We provide a function to binary result images, and you can call the bwfunction to use it.

  4. We also provide scripts to calculate PD & FA of our inference result. And the same statistical method was used in the comparative experiment.

Command : python statistic.py --image_path (path saved result) --label_path (path saved ground truth) --width 896 --height 896

objectdetection's People

Contributors

littlepieces avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.