Skip to content

wokaikaixinxin/ai4rs

Repository files navigation

visitors GitHub Repo stars

Introduction 👋

We hope to integrate remote sensing related work based on MMLab, especially MMDetection and MMRotate.

Model Zoo 🐅

Real Time
Rotated YOLOX (arXiv 2021) RTMDet (arXiv 2022) Rotated YOLOMS (TPAMI 2025) RTDETR (CVPR' 2024)
O2-RTDETR (TGRS 2026)
Oriented Object Detection - Architecture
Rotated RetinaNet-OBB/HBB
(ICCV'2017)
Rotated FasterRCNN-OBB
(TPAMI'2017)
Rotated RepPoints-OBB
(ICCV'2019)
Rotated FCOS
(ICCV'2019)
RoI Transformer
(CVPR'2019)
Gliding Vertex
(TPAMI'2020)
Rotated ATSS-OBB
(CVPR'2020)
R3Det
(AAAI'2021)
S2A-Net
(TGRS'2021)
ReDet
(CVPR'2021)
Beyond Bounding-Box
(CVPR'2021)
Oriented R-CNN
(ICCV'2021)
Rotated YOLOX
(arXiv 2021)
Rotated Deformable DETR
(ICLR'2021)
SASM
(AAAI'2022)
Oriented RepPoints
(CVPR'2022)
RTMDet
(arXiv 2022)
Rotated DiffusionDet
(ICCV'2023)
Rotated DINO
(ICLR 2023)
OrientedFormer
(TGRS' 2024)
RTDETR
(CVPR' 2024)
ReDiffDet base
(CVPR'2025)
GSDet base
(IJCAI'2025)
Rotated YOLOMS
(TPAMI 2025)
MessDet
(ICCV'2025)
AMMBA
(TGRS'2025)
RHINO
(WACV'2025)
HERO
(AAAI'2026)
O2-RTDETR
(TGRS' 2026)
Oriented Object Detection - Loss
GWD
(ICML'2021)
KLD
(NeurIPS'2021)
KFIoU
(ICLR'2023)
Oriented Object Detection - Coder
CSL
(ECCV'2020)
Oriented R-CNN
(ICCV'2021)
PSC
(CVPR'2023)
ACM
(CVPR'2024)
GauCho
(CVPR'2025)
Oriented Object Detection - Backbone
ConvNeXt
(CVPR'2022)
LSKNet
(ICCV'2023)
ARC
(ICCV'2023)
PKINet
(CVPR'2024)
SARDet 100K
(Nips'2024)
GRA
(ECCV'2024)
LEGNet
(ICCVW'2025)
Strip R-CNN
(AAAI'2026)
LWGANet
(AAAI'2026)
Fourier Angle Align
(CVPR'2026)
Oriented Object Detection - Weakly Supervise
H2RBox
(ICLR'2023)
H2RBox-v2
(Nips'2023)
Point2Rbox
(CVPR'2024)
Point2Rbox-v2
(CVPR'2025)
WhollyWOOD
(TPAMI'2025)
ABBSPO
(CVPR'2025)
Oriented Object Detection - Semi Supervise

Coming soon

SAR
SARDet 100K (Nips'2024) RSAR (CVPR'2025)
SAM
MMRotate SAM
Scene graph generation (SGG)
STAR (TPAMI'2025) ReCon1M (TGRS'2025)
Change Detection
FC-EF (ICIP'2018) FC-Siam-conc (ICIP'2018) FC-Siam-diff (ICIP'2018) Changer (TGRS'2023)
BiT (TGRS' 2021) IDA-SiamNet (TGRS' 2024)
Instance Segmentation
CATNet (TNNLS'2024)

Installation ⚙️ Bilibili

To support H2rbox_v2, point2rbox, and mamba, we use pytorch-2.x.

Step 1: Install Anaconda or Miniconda

Step 2: Create a virtual environment

conda create --name ai4rs python=3.10 -y
conda activate ai4rs

Step 3: Install Pytorch according to official instructions. For example:

pip install torch==2.4.0 torchvision==0.19.0 torchaudio==2.4.0 --index-url https://download.pytorch.org/whl/cu121

Verify whether pytorch supports cuda

python -c "import torch; print(torch.cuda.is_available())"

Step 4: Install MMEngine and MMCV, and we recommend using MIM to complete the installation

pip install -U openmim -i https://pypi.tuna.tsinghua.edu.cn/simple
mim install mmengine -i https://pypi.tuna.tsinghua.edu.cn/simple
mim install "mmcv==2.2.0" -i https://pypi.tuna.tsinghua.edu.cn/simple

Step 5: Install MMDetection and MMSegmentation(for change detection)

mim install 'mmdet>3.0.0rc6, <3.4.0' -i https://pypi.tuna.tsinghua.edu.cn/simple
mim install "mmsegmentation>=1.2.2" -i https://pypi.tuna.tsinghua.edu.cn/simple

Change the version number in the mmdet code.

python -c "import mmdet; print(mmdet.__file__)"
# ...
#   File "/root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmdet/__init__.py", line 17, 
#     in <module> and mmcv_version < digit_version(mmcv_maximum_version)), \
# AssertionError: MMCV==2.2.0 is used but incompatible. Please install mmcv>=2.0.0rc4, <2.2.0.

modify /root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmdet/__init__.py

vim '/root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmdet/__init__.py'
# mmcv_maximum_version = '2.2.0' -> '2.3.0'

Change the version number in the mmseg code.

python -c "import mmseg; print(mmseg.__file__)"
# ...
#   File "/root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmseg/__init__.py", line 61,
#      in <module> assert (mmcv_min_version <= mmcv_version < mmcv_max_version), \
# AssertionError: MMCV==2.2.0 is used but incompatible. Please install mmcv>=2.0.0rc4.

modify /root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmseg/__init__.py

vim '/root/anaconda3/envs/ai4rs/lib/python3.10/site-packages/mmseg/__init__.py'
# MMCV_MAX = '2.2.0' -> '2.3.0'

Step 6: Install ai4rs

git clone https://github.com/wokaikaixinxin/ai4rs.git
cd ai4rs

Option 1: Basic Installation
Use this for a lightweight setup with only the core functional dependencies.

pip install -v -e . -i https://pypi.tuna.tsinghua.edu.cn/simple
# "-v" means verbose, or more output
# "-e" means installing a project in editable mode,
# thus any local modifications made to the code will take effect without reinstallation.

Option 2: Full Installation (Recommended)
Use this if you want all features and dependencies (e.g., change detection).

pip install -v -e .[all] -i https://pypi.tuna.tsinghua.edu.cn/simple

Data Preparation 🗃️

Please refer to data_preparation.md to prepare the data

DOTA (CVPR'2018) DIOR (TGRS'2022) SSDD (RS'2021) HRSC (ICPRAM'2017)
HRSID (Access'2020) SRSDD (RS'2021) RSDD (Journal of Radars'2022) ICDAR2015 (ICDAR'2015)
SARDet 100K (Nips'2024) RSAR (CVPR'2025) FAIR1M (ISPRS'2022) STAR (TPAMI'2025)
ReCon1M (TGRS'2025) CODrone (Arxiv'2025) KFGOD (RS'2025) LEVIR-CD (TGRS'2020)
iSAID (CVPRW'2019) DroneVehicle (TCSVT'2022)

Train 📈

Single-node single-GPU

python tools/train.py config_path

For example:

python tools/train.py projects/GSDet_baseline/configs/GSDet_r50_b900_h2h4_h2r1_r2r1_2x_dior.py

Single-node multi-GPU

bash tools/dist_train.sh config_path num_gpus

For example:

bash tools/dist_train.sh projects/GSDet_baseline/configs/GSDet_r50_b900_h2h4_h2r1_r2r1_2x_dior.py 2

Test 🧪

Single-node single-GPU

python tools/test.py config_path checkpoint_path

For example:

python tools/test.py configs/h2rbox_v2/h2rbox_v2-le90_r50_fpn-1x_dota.py work_dirs/h2rbox_v2-le90_r50_fpn-1x_dota-fa5ad1d2.pth

Single-node multi-GPU

bash tools/dist_test.sh config_path checkpoint_path num_gpus

For example:

bash tools/dist_test.sh configs/h2rbox_v2/h2rbox_v2-le90_r50_fpn-1x_dota.py work_dirs/h2rbox_v2-le90_r50_fpn-1x_dota-fa5ad1d2.pth 2

Getting Started 🚀

Please see Overview for the general introduction of Openmmlab.

For detailed user guides and advanced guides, please refer to our documentation:

FAQ 🤔

Please refer to FAQ for frequently asked questions.

Acknowledgement 🙏

OpenMMLab

OpenMMLab platform

MMDetection

MMRotate

open-cd

Citation 🌟

If you use this toolbox or benchmark in your research, please cite this project ai4rs

If you find this project helpful, please give us a star!