Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/whywhs/Detection_and_Recognition_in_Remote_Sensing_Image
This work uses PaNet to realize Detection and Recognition in Remote Sensing Image by MXNet
https://github.com/whywhs/Detection_and_Recognition_in_Remote_Sensing_Image
Last synced: 2 months ago
JSON representation
This work uses PaNet to realize Detection and Recognition in Remote Sensing Image by MXNet
- Host: GitHub
- URL: https://github.com/whywhs/Detection_and_Recognition_in_Remote_Sensing_Image
- Owner: whywhs
- License: apache-2.0
- Created: 2019-02-13T09:10:03.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2019-03-06T08:35:00.000Z (almost 6 years ago)
- Last Synced: 2024-08-01T22:40:28.274Z (5 months ago)
- Language: Python
- Homepage:
- Size: 2.07 MB
- Stars: 23
- Watchers: 4
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- Awesome-MXNet - Detection and Recognition in Remote Sensing Image
README
# Detection_and_Recognition_in_Remote_Sensing_Image
## Notice
This code is writting with reference to this [paper](https://arxiv.org/abs/1711.10398) by Hongyu Wang in Beihang University, and the code is built upon a fork of [Deformble Convolutional Networks](https://github.com/msracver/Deformable-ConvNets) and [Faster RCNN for DOTA](https://github.com/jessemelpolio/Faster_RCNN_for_DOTA).@InProceedings{Xia_2018_CVPR,
author = {Xia, Gui-Song and Bai, Xiang and Ding, Jian and Zhu, Zhen and Belongie, Serge and Luo, Jiebo and Datcu, Mihai and Pelillo, Marcello and Zhang, Liangpei},
title = {DOTA: A Large-Scale Dataset for Object Detection in Aerial Images},
booktitle = {The IEEE Conference on Computer Vision and Pattern Recognition (CVPR)},
month = {June},
year = {2018}
}In my code, I have tried different approaches mainly on the following points:
1. Replace Faster_RCNN with [PANet](https://arxiv.org/abs/1803.01534).
2. A new loss function called [Focal Loss](https://arxiv.org/abs/1708.02002) is attempted.
## Requirements: Software1. MXNet from [the offical repository](https://github.com/dmlc/mxnet). We tested our code on [MXNet@(commit 62ecb60)](https://github.com/dmlc/mxnet/tree/62ecb60). Due to the rapid development of MXNet, it is recommended to checkout this version if you encounter any issues.
2. Python 2.7. We recommend using Anaconda2 to manage the environments and packages.
3. Some python packages: cython, opencv-python >= 3.2.0, easydict. If `pip` is set up on your system, those packages should be able to be fetched and installed by running:
```
pip install Cython
pip install opencv-python==3.2.0.6
pip install easydict==1.6
```
4. For Windows users, Visual Studio 2015 is needed to compile cython module.## Requirements: Hardware
Any NVIDIA GPUs with at least 4GB memory should be sufficient.
## Installation
For Windows users, run ``cmd .\init.bat``. For Linux user, run `sh ./init.sh`. The scripts will build cython module automatically and create some folders.
## Preparation for Training & Testing
1. Please download [DOTA](https://captain-whu.github.io/DOTA/dataset.html) dataset, use the [DOTA_devkit](https://github.com/CAPTAIN-WHU/DOTA_devkit) to split the data into patches. And make sure the split images look like this:
```
./path-to-dota-split/images
./path-to-dota-split/labelTxt
./path-to-dota-split/test.txt
./path-to-dota-split/train.txt
```
The test.txt and train.txt are name of the subimages(without suffix) for train and test respectively.2. Please download ImageNet-pretrained ResNet-v1-101 model manually from [OneDrive](https://1drv.ms/u/s!Am-5JzdW2XHzhqMEtxf1Ciym8uZ8sg), or [BaiduYun](https://pan.baidu.com/s/1YuB5ib7O-Ori1ZpiGf8Egw#list/path=%2F), or [Google drive](https://drive.google.com/open?id=1b6P-UMaBBpMPlcgvc38dMToPAa_Gyu6F), and put it under folder `./model`. Make sure it look like this:
```
./model/pretrained_model/resnet_v1_101-0000.params
```## Usage
1. All of our experiment settings (GPU #, dataset, etc.) are kept in yaml config files at folder `./experiments/faster_rcnn/cfgs`.
2. Set the "dataset_path" and "root_path" in DOTA.yaml and DOTA_quadrangle.yaml. The "dataset_path" should be the father folder of "images" and "labelTxt". The "root_path" is the path you want to save the cache data.
3. Set the scales and aspect ratios as your wish in DOTA.yaml and DOTA_quadrangle.yaml.
4. To conduct experiments, run the python scripts with the corresponding config file as input. For example, train and test on quadrangle in an end-to-end manner, run
```
python experiments/faster_rcnn/rcnn_dota_quadrangle_e2e.py --cfg experiments/faster_rcnn/cfgs/DOTA_quadrangle.yaml
```
## Experiment
![1](http://m.qpic.cn/psb?/V13MmUWH1KBoey/*BFUf.2lJRfuUnCYSvvw4A.qWqoUMr04jdaXDLOl3hc!/b/dL8AAAAAAAAA&bo=AAQABAAAAAARBzA!&rf=viewer_4)![1](http://m.qpic.cn/psb?/V13MmUWH1KBoey/LPMnoc2CkeQeQZYHMXzAqjD9FbKFBRlsemughV2ZdBw!/b/dFIBAAAAAAAA&bo=AAQABAAAAAARJxA!&rf=viewer_4)
![1](http://m.qpic.cn/psb?/V13MmUWH1KBoey/MVMMx6IaJq5rIdeJlHcIJFSr6vn4gha3LLHQKwpi4aY!/b/dL8AAAAAAAAA&bo=AAQABAAAAAARJxA!&rf=viewer_4)
![1](http://m.qpic.cn/psb?/V13MmUWH1KBoey/6bqrWMFMDhft1BVVcJQoE8E6WH7xn0e0mq1283J0.7M!/b/dL8AAAAAAAAA&bo=VQMABAAAAAARF3I!&rf=viewer_4)