Skip to content
/ yolt Public
forked from avanetten/yolt

You Only Look Twice: Rapid Multi-Scale Object Detection In Satellite Imagery

License

Notifications You must be signed in to change notification settings

CosmiQ/yolt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YOLT

You Only Look Twice: Rapid Multi-Scale Object Detection In Satellite Imagery

YOLT is an extension of the YOLO framework that can evaluation satellite images of arbitrary size, and runs at ~50 frames per second.

The YOLT code alters a number of the files in src/*.c to allow further functionality. We also build a python wrapper around the C functions to improve flexibility. We utililize the default data format of YOLO, which places images and labels in different forlders.
An example training data and image:

/data/images/train1.tif /data/labels/train1.txt

Each line of the .txt file has the format

Where x, y, width, and height are relative to the image's width and height.

Labels can be created with LabelImg, and converted to the appropriate format with the /yolt/scripts/convert.py script.

For more information, see:

  1. arXiv paper: You Only Look Twice: Rapid Multi-Scale Object Detection In Satellite Imagery

  2. Blog1: You Only Look Twice — Multi-Scale Object Detection in Satellite Imagery With Convolutional Neural Networks (Part I)

  3. Blog2: You Only Look Twice (Part II) — Vehicle and Infrastructure Detection in Satellite Imagery

  4. Blog3: Building Extraction with YOLT2 and SpaceNet Data

  5. Blog4: Car Localization and Counting with Overhead Imagery, an Interactive Exploration

  6. Blog5: The Satellite Utility Manifold; Object Detection Accuracy as a Function of Image Resolution

  7. Blog6: https://medium.com/the-downlinq/panchromatic-to-multispectral-object-detection-performance-as-a-function-of-imaging-bands-51ecaaa3dc56

If you plan on using YOLT in your work, please consider citing YOLO and YOL

############################################## ##############################################

Execution

##############################################

HELP

python yolt2.py --help

##############################################

COMPILE (gpu machine)

python yolt2.py
--mode compile

##############################################

TRAIN (gpu_machine)

# e.g.: boats and planes python ../scripts/yolt2.py
--mode train
--outname 3class_boat_plane
--object_labels_str boat,boat_harbor,airplane
--cfg_file ave_13x13.cfg
--nbands 3
--weight_file ave_13x13_boats_planes_voc.weights
--train_images_list_file boat_airplane_all.txt
--single_gpu_machine 0
--keep_valid_slices False
--max_batches 60000
--gpu 1

##############################################

VALIDATE (gpu_machine)

# test on all: boats, cars, and airplanes with new model cd /raid/local/src/yolt2/results/ python ../scripts/yolt2.py
--mode valid
--outname qgis_labels_all_boats_planes_cars_buffer
--object_labels_str airplane,airport,boat,boat_harbor,car
--cfg_file ave_26x26.cfg
--valid_weight_dir train_cowc_cars_qgis_boats_planes_cfg=ave_26x26_2017_11_28_23-11-36
--weight_file ave_26x26_30000_tmp.weights
--valid_testims_dir qgis_validation/all
--keep_valid_slices False
--valid_make_pngs True
--valid_make_legend_and_title False
--edge_buffer_valid 1
--valid_box_rescale_frac 1
--plot_thresh_str 0.4
--slice_sizes_str 416
--slice_overlap 0.2
--gpu 2

##############################################

TBD:

  1. Upload data preparation scripts
  2. Describe multispectral data handling
  3. Describle initial results with YOLOv3
  4. Describle better labeling methods

About

You Only Look Twice: Rapid Multi-Scale Object Detection In Satellite Imagery

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 79.2%
  • Python 7.8%
  • C++ 6.4%
  • Cuda 6.3%
  • Makefile 0.2%
  • Dockerfile 0.1%