README.md

July 6, 2021 ยท View on GitHub

A Simple Codebase for Image-based Person Re-identification

Requirements: Python 3.6, Pytorch 1.6.0, yacs

Supported losses

Classification Losses
  • CrossEntropy Loss
  • CrossEntropy Loss with Label Smooth
  • CosFace Loss
  • ArcFace Loss
  • Circle Loss
Pairwise Losses
  • Triplet Loss
  • Contrastive Loss
  • Pairwise CosFace Loss
  • Pairwise Circle Loss

Supported models

  • ResNet-50
  • ResNet-50-IBN
  • IANet

Get Started

  • Replace _C.DATA.ROOT and _C.OUTPUT in configs/default.py with your own data path and output path, respectively.
  • Run train.sh

Some Results

Market-1501
classification losspairwise lossbackbonetop-1mAP
CrossEntropyTripletResNet-5094.586.6
CrossEntropyContrastiveResNet-5094.386.4
CrossEntropyCosfaceResNet-5094.386.2
CELabelSmoothTripletResNet-5095.087.4
CELabelSmoothContrastiveResNet-5094.587.1
CELabelSmoothCosfaceResNet-5094.186.4
CosfaceTripletResNet-5095.186.7
CosfaceCosfaceResNet-5094.587.1
ArcfaceTripletResNet-5094.286.3
CircleCircleResNet-5094.787.3
MSMT
classification losspairwise lossbackbonetop-1mAP
CrossEntropyTripletResNet-5078.957.0
CrossEntropyContrastiveResNet-5079.356.7
CrossEntropyCosfaceResNet-5078.255.2
CELabelSmoothTripletResNet-5079.958.0
CELabelSmoothContrastiveResNet-5080.358.7
CELabelSmoothCosfaceResNet-5079.256.6
CosfaceTripletResNet-5078.154.1
CosfaceCosfaceResNet-5078.855.9
ArcfaceTripletResNet-5078.254.2
CircleCircleResNet-5079.757.0

Citation

If you use our code in your research or wish to refer to the baseline results, please use the following BibTeX entry.

@InProceedings{CVPR2019IANet
author = {Hou, Ruibing and Ma, Bingpeng and Chang, Hong and Gu, Xinqian and Shan, Shiguang and Chen, Xilin},
title = {Interaction-And-Aggregation Network for Person Re-Identification},
booktitle = {CVPR},
year = {2019}
}