Minho Shim, Hsuan-I Ho, Jinhyung Kim, and Dongyoon Wee
This repository contains demo software for the READ (ECCV 2020).
- CUDA 9.0
- Python 3.5.2
- PyTorch 0.4.1
- OpenCV 3.4.7
- H5py
- SciPy
Unzip bbox_train.zip
and bbox_test.zip
, alongside with mat
/txt
files.
(Links: zips, mats/txts from the MARS authors' repo)
The directory will look like:
path/to/mars_raw/
|-- bbox_train/
|-- bbox_test/
|-- info/
Then run:
python dataset/mars/mars_jpgs_to_h5.py --top-dir path/to/mars_raw/ --output-dir path/to/mars_h5/
python dataset/mars/mars_extract_json.py -d path/to/mars_h5/ -o path/to/mars_h5/mars.min.json
Download links to weight files for MARS, and DukeMTMC-VideoReID.
python play.py --test --dataset mars --json-path path/to/mars_h5/mars.min.json --h5-dir path/to/mars_h5/ --checkpoint-files '{"all":"[downloaded_checkpoint_path]"}'
By default, it uses all available GPUs in the machine.
It could be limited with CUDA_VISIBLE_DEVICES
, e.g. CUDA_VISIBLE_DEVICES=0,1,2,3 python ...
Adjust --batch-size
accordingly to your GPU capacity. In our case, P40 or V100 GPUs are used with the default batch size of 32.
python play.py --test --dataset mars --checkpoint-files '{"all":"/volume/READ/mars_demo.tar"}' --json-path /volume/dataset/mars_h5/mars.min.json --h5-dir /volume/dataset/mars_h5/
...
Test Results:
mean_average_precision: 0.7039292454719543
mean_top10: 0.9383838176727295
mean_top5: 0.9207070469856262
mean_top1: 0.8146464824676514
@InProceedings{shim2020read,
author = {Shim, Minho and Ho, Hsuan-I and Kim, Jinhyung and Wee, Dongyoon},
title = {{READ}: {R}eciprocal Attention Discriminator for Image-to-Video Re-Identification},
booktitle = {European Conference on Computer Vision (ECCV)},
year = {2020}
}
This software is for non-commercial use only. Imported/modified codes contain their own references inside each code.