Beyond Part Models: Person Retrieval with Refined Part Pooling
This repository tries to implement the paper:Beyond Part Models: Person Retrieval with Refined Part Pooling and I almost follow the training details at the origin paper.
Feature | mAP(%) | Rank-1(%) | |
---|---|---|---|
PCB(paper) | G | 77.4 | 92.3 |
PCB(paper) | H | 77.3 | 92.4 |
PCB(ours) | G | 78.6 | 92.7 |
PCB(ours) | H | 78.5 | 92.1 |
PCB+RPP(paper) | G | 81.6 | 93.8 |
PCB+RPP(paper) | H | 81.0 | 93.1 |
PCB+RPP(ours) | G | 80.7 | 92.8 |
PCB+RPP(ours) | H | 79.8 | 92.4 |
prepare.py
and run python prepare.py
to prepare the datasetTrain the model:
python train.py --gpu_ids 0,1 --batchsize 64 --data_dir your_data_path --save_dir your_model_save_path --RPP True
--gpu_ids
: single GPU or mutil-GPUs--batchsize
: batch size--data_dir
: the path of the preparing data--save_dir
: the path to save the training model--RPP
: whether to train with RPP
I train the model on the two GPUs with 64 batchsizeTest the model(extract the features):
python test.py --gpu_ids 0 --which_epoch select the model --stage PCB or full --RPP True or False --feature_H True or False
--gpu_ids
: just single GPU--which_epoch
: select the i-th model--stage
: select the training model : PCB or full(PCB+RPP)--RPP
: if you choose the PCB model, RPP to False; if you choose the full model, RPP to True--feature_H
: whether to extract the low-dims featuresEvaluate the model
python evaluate_gpu.py --gpu_ids 0 --reslut_mat the path of the features mat
python evaluate_gpu.py --reslut_mat the path of the features mat
Thanks to the layumi/Person_reID_baseline_pytorch. This repository only implements the part of PCB, I make some modifications on it and then add the RPP part.