/LRIMV

Primary LanguagePython

Python >=3.5 PyTorch >=1.0

Logical Relation Inference and Multi-view Information Interaction for Domain Adaptation Person Re-identification

The official repository for [Logical Relation Inference and Multi-view Information Interaction for Domain Adaptation Person Re-identification].

Pipeline

framework

Requirements

Installation

pip install -r requirements.txt
(we use /torch 1.8.0 /torchvision 0.9.0 /timm 0.4.12 /cuda 11.1.1 / 24G  RTX3090 for training and evaluation.)

Prepare Datasets

mkdir data

Download the person datasets Market-1501, MSMT17, DukeMTMC-reID, MSMT17-New ,Market1501-New. Then unzip them and rename them under the directory like.

data
├── market1501
│   └── images ..
├── dukemtmcreid
│   └── images ..
└── MSMT17
    └── images ..

Prepare ViT Pre-trained Models

You need to download the ImageNet pretrained transformer model : ViT-Base

Example #1 :

Transferring from DukeMTMC-reID to Market-1501.

Train

We utilize 1 RTX-3090 GPU for training.

Stage I: Pre-training on the source domain

python pre_source.py --config_file configs/vit_base_pre_duke.yml

Stage II: End-to-end training target domain

python train.py --config_file configs/d2m.yml

Evaluation

python test.py --config_file configs/d2m.yml

Download Trained Models

Our LRIMV models in the paper will be able to downloaded from the link.

Acknowledgement

Our code is based on TransReID and MMT.