Code Monkey home page Code Monkey logo

otla-reid's Introduction

Optimal Transport for Label-Efficient Visible-Infrared Person Re-Identification (OTLA-ReID)

This is Official Repository for "Optimal Transport for Label-Efficient Visible-Infrared Person Re-Identification" (PDF, Supplementary Material), which is accepted by ECCV 2022. This work is done at the DMCV Laboratory of East China Normal University. You can link at DMCV-Lab to find DMCV Laboratory website page.

main_figure

Update:

[2022-7-17] Semi-supervised setting and supervised setting can be run with current code. Unsupervised setting will be updated with a few of days.

[2022-7-21] Update some critical informtion of REAMDE.md.

[2022-9-22] Update the code of SpCL-master, which can be used to generator pseudo labels of visible modality for unsupervised setting.

[2022-10-28] Update the paper link.

Requirements

  • python 3.7.11
  • numpy 1.21.4
  • torch 1.10.0
  • torchvision 0.11.0
  • easydict 1.9
  • PyYAML 6.0
  • tensorboardX 2.2

Prepare Datasets

Download the VI-ReID datasets SYSU-MM01 (Email the author to get it) and RegDB (Submit a copyright form). follow the link of DDAG to obtain more information of VI-ReID datasets. Download visible ReID datasets Market-1501, MSMT17 (Email the author to get it), DukeMTMC-reID if you want to run unsupervised setting. Please follow the link of OpenUnReID to obtain more information of visible ReID datasets.

Training

You need to firstly choose the setting: of config file corresponding VI-ReID dataset.

  • For semi-supervised / supervised setting, if you want to train the model(s) in the paper, run following command:
cd OTLA-ReID/
python main_train.py --config config/config_sysu.yaml
  • For unsupervised setting, you should write the right path of train_visible_image_path: and train_visible_label_path: , which are the produced visible data and pseudo label path of VI-ReID datasets by well-established UDA-ReID or USL-ReID methods (e.g. SpCL). Then run following command:
cd OTLA-ReID/
python main_train.py --config config/config_sysu.yaml

Here, we give an example of running SpCL to generate visible pseudo label in SpCL-master. However, you firstly need to install environment which can be found in SpCL:

  • For SYSU-MM01:
cd OTLA-ReID/SpCL-master/
CUDA_VISIBLE_DEVICES=0,1,2,3 python examples/spcl_train_uda.py -ds market1501 -dt sysumm01_rgb --logs-dir logs/spcl_uda/market1501TOsysumm01_rgb_resnet50 --epochs 51 --iters 800
  • For RegDB:
cd OTLA-ReID/SpCL-master/
CUDA_VISIBLE_DEVICES=0,1,2,3 python examples/spcl_train_uda.py -ds market1501 -dt regdb_rgb --logs-dir logs/spcl_uda/regdbTOsysumm01_rgb_resnet50 --epochs 51 --iters 50

The generated visible images and visible pseudo labels are both saved under the dataset directory.

Testing

If you want to test the trained model(s), run following command:

cd OTLA-ReID/
python main_test.py --config config/config_sysu.yaml --resume --resume_path ./sysu_semi-supervised_otla-reid/sysu_save_model/best_checkpoint.pth

Citation

If you find this code useful for your research, please cite our paper:

@inproceedings{wang2022optimal,
  title={Optimal Transport for Label-Efficient Visible-Infrared Person Re-Identification},
  author={Wang, Jiangming and Zhang, Zhizhong and Chen, Mingang and Zhang, Yi and Wang, Cong and Sheng, Bin and Qu, Yanyun and Xie, Yuan},
  booktitle={European Conference on Computer Vision},
  pages={93--109},
  year={2022},
  organization={Springer}
}

Acknowledgements

This work is developed based on repositories of SeLa(ICLR 2020), DDAG(ECCV 2020), SpCL(NIPS 2020), MMT(ICLR 2020), HCD(ICCV 2021). We sincerely thanks all developers of these high-quality repositories.

otla-reid's People

Contributors

wjm-wjm 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.