Giter VIP home page Giter VIP logo

avm_rot's Introduction

AVM

环境

最佳实践(推荐,已测试可行)

  1. 第一步 使用 MIM 安装 MMCV
pip install -U openmim
mim install mmcv-full
  1. 第二步 安装 MMRotate
pip install mmrotate
  1. 第三步下载配置文件(可选)
mim download mmrotate --config oriented_rcnn_r50_fpn_1x_dota_le90 --dest .

训练

在当前目录下建立软连接

ln -s AVM_DATA_ROOT avm

其中AVM原始数据集目录需调整为如下结构

avm
 │
 ├─ images
 │   ├─ b2_left
 │   │   └─ avm
 │   │       ├─ 0.jpg
 │   │       └─ 20.jpg
 │   │       ... 
 │   ├─ b2_right
 │   ├─ b2_to_b3
 │   └─ b3_to_b2
 │   
 └─ det_annotations
     ├─ b2_left
     │   ├─ 0.json
     │   └─ 20.json
     │   ... 
     ├─ b2_right
     ├─ b2_to_b3
     └─ b3_to_b2

将原数据集格式转换为DOTA格式

python create_data.py --avm-dir ./data/avm --output-dir ./data/avm_dota_format

转换过后文件结构如下:

avm_cs_format
 │
 └─ train
     ├─ annfiles
     │   ├─ b2_left_0.txt
     │   └─ b2_left_1000.txt
     │       ... 
     └─ images
         ├─ b2_left_0.png
         └─ b2_left_1000.png
         ... 
 

推理

python inference.py --config=configs/rotated_retinanet_obb_r50_fpn_1x_avm_le90.py --checkpoint=checkpoints/epoch_3.pth --image_path=demo.png

结果将保存为bin文件,读取后reshape成(-1, 7),则7个维度分别对应 (x, y, w, h, theta, score, label)。

avm_rot's People

Contributors

dekuliutesla avatar

Watchers

 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.