The code is for AI City Challenge 2019 Track1, MTMC Vehicle Tracking.
And we got the second place.
Peilun Li, Guozhen Li, Meiqi Lu, Zhangxi Yan, Youzeng Li
Dateset download: Track1-download,Size: 16.2GB
For running code correctly, the data should be put as follows:
├─ aic19-track1-mtmc
│ ├─ train
│ │ ├─ S01
│ │ │ ├─ c001
│ │ │ │ ├─ det
│ │ │ │ ├─ gt
│ │ │ │ ├─ mtsc
│ │ │ │ ├─ segm
│ │ │ │ ├─ calibration.txt
│ │ │ │ ├─ roi.jpg
│ │ │ │ ├─ det_reid_features.txt
│ │ │ │ ├─ vdo.avi
│ │ │ ├─ c002
│ │ │ ├─ c003
│ │ │ ├─ c004
│ │ │ ├─ c005
│ │ ├─ S03
│ │ ├─ S04
│ ├─ test
│ │ ├─ S02
│ │ ├─ S05
│ └─ cam_timestamp
Note that the det_reid_features.txt
is the middle result of 1b_merge_visual_feature_with_ other_feature.py
, and the other files are provided by organisers.
For each bounding box, crop the vehicle image and calculate the gps, according to the results of detection.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
output:
- for each video, produce
det_gps_feature.txt
to save gps information - for each video, save all cropped image.
- extract reid feature for each corpped image, the train and inference pipeline follows reid-baseline
Merge reid feature and gps information into one file.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- gps information file
/det_gps_feature.txt
, from1
- ReID feature file
/deep_features.txt
, from1a
output:
- for each video, produce
det_reid_features.txt
file
multi targets tracking for each video.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- ID file
already_used_number.txt
, avoid reusing number /det_reid_features.txt
from1b
output:
- for each video, produce tracking result file
det_reid_track.txt
Optimize tracking result to solve target lost.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- fps file
train_fps.txt
- for each video, need
det_reid_track.txt
from2
output:
- for each video, produce tracking result
optimized_track.txt
Remove overlapped bounding box.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- for each video, need
optimized_track.txt
from2a
output:
- for each video, produce tracking result
optimized_track_no_overlapped.txt
Calculate reid similarity between tracks.
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- for each video, need
optimized_track_no_overlapped.txt
from2b
output:
- ReID similarity file
ranked
Calculate the gps-trajectory cohesion between tracks, should run the code trajectory_processing/main.py
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- for each video, need
optimized_track_no_overlapped.txt
from2b
output:
- gps-trajectroy file
gps_and_time_new
MTMC tracking for crossroad scene
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- for each video, need
optimized_track_no_overlapped.txt
from2b
ranked
from3a
gps_and_time_new
from3b
output:
- match result
submission_crossroad_train
MTMC tracking for arterial road scene
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
- for each video, need
optimized_track_no_overlapped.txt
from2b
ranked
from3a
gps_and_time_new
from3b
output:
- match result
submission_normal_train
merge the results from different scenes
input:
submission_crossroad_train
from4a
submission_normal_train
from4b
output:
- merged result file
submission
post process for each bounding box
input:
- input_dir:
./aic19-track1-mtmc/train
or./aic19-track1-mtmc/test
submission
from5a
output:
- result file
submission_adpt
convert the result to submission format
input:
submission_adpt
from5b
output:
- submission file
track1.txt
Run the code from 1_\*.py
to 5c_\*.py
orderly.
The train and inference for ReID follows reid-baseline
We propose starting with 2_tracking.py
, if you are the first time to this project. And we provide the results of 1b
.
You could download it, put them in the right place as metioned above and rename them as det_reid_features.txt
.
result of 1b