yyyyll0ss / CVNet

[TGRS 2023] When Vectorization Meets Change Detection

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CVNet

This is Pytorch implementation for "When Vectorization Meets Change Detection". If you have any questions, please contact yanyl@hnu.edu.cn

Overview

The overall framework for CVNet. image

Installation

Ubuntu-18.04, CUDA 11.0, pytorch1.7/1.8, GCC 7.3

conda create -n cvnet python=3.7
conda activate cvnet
conda install pytorch==1.7.0 torchvision==0.8.0 cudatoolkit=11.0 -c pytorch

cd cvnet
conda develop .
pip install -r requirements.txt

For evaluation with boundary IoU, please install boundary IoU API following the installation instruction.

Training & Testing

Data prepare

Please put the change vectorization datasets into datasets folder. The datasets folder is constructed as follows:

code_root/
└── data/
    └── WHU_VectorCD/
        ├── train/
            ├── A
            ├── B
            └── annotation.json
        └── val/
            ├── A
            ├── B
            └── annotation.json
    └── LEVIR_VectorCD/
        ├── train/
            ├── A
            ├── B
            └── annotation.json
        └── val/
            ├── A
            ├── B
            └── annotation.json

Training

The model with HRNetV2 as backbone are initialized with imagenet pretrained parameters. You could download them from https://github.com/HRNet/HRNet-Image-Classification and put them in the path of ./CVNet/backbones/hrnet_imagenet.

bash train.sh
bash unite_train.sh

Testing

bash test.sh

Evaluation

We provide implementation of different metrics for evaluation. You can run the following command to evaluate the test results in MS-COCO format.

python tools/evaluation.py --gt-file [GT_ANNOTATION_FILE] --dt-file [PREDICT_ANNOTATION_FILE] --eval-type boundary_iou

Acknowledgement

This repo benefits from HiSup, ECA-Net, HR-Net, boundary iou api. We thank the authors for their great work.

BibTeX

@article{yan2023vectorization,
  title={When Vectorization Meets Change Detection},
  author={Yan, Yinglong and Yue, Jun and Lin, Jiaxing and Guo, Zhengyang and Fang, Yi and Li, Zhenhao and Xie, Weiying and Fang, Leyuan},
  journal={IEEE Transactions on Geoscience and Remote Sensing},
  year={2023},
  publisher={IEEE}
}

About

[TGRS 2023] When Vectorization Meets Change Detection


Languages

Language:Python 97.6%Language:C++ 1.6%Language:Cuda 0.6%Language:Cython 0.1%Language:Shell 0.1%Language:Makefile 0.0%