mmtracking
mmtracking copied to clipboard
DeepSort with Yolox
Hi! Is it possible to run DeepSort with Yolox model? I make the config, using my own detector but in the end I get zero tracks and detections. At the same time, the same detector works great with ByteTrack and Ocsort. What could be the problem?
Example config :
_base_ = [
'../../_base_/models/yolox_x_8x8.py',
'../../_base_/datasets/mot_challenge.py', '../../_base_/default_runtime.py'
]
img_scale = (640, 640)
model = dict(
type='DeepSORT',
detector=dict(
input_size=img_scale,
random_size_range=(18, 32),
bbox_head=dict(num_classes=1),
test_cfg=dict(score_thr=0.8, nms=dict(type='nms', iou_threshold=0.5)),
init_cfg=dict(
type='Pretrained',
checkpoint= 'path_to_detector'
)),
motion=dict(type='KalmanFilter', center_only=False),
reid=dict(
type='BaseReID',
backbone=dict(
type='ResNet',
depth=50,
num_stages=4,
out_indices=(3, ),
style='pytorch'),
neck=dict(type='GlobalAveragePooling', kernel_size=(8, 4), stride=1),
head=dict(
type='LinearReIDHead',
num_fcs=1,
in_channels=2048,
fc_channels=1024,
out_channels=128,
num_classes=380,
loss=dict(type='CrossEntropyLoss', loss_weight=1.0),
loss_pairwise=dict(
type='TripletLoss', margin=0.3, loss_weight=1.0),
norm_cfg=dict(type='BN1d'),
act_cfg=dict(type='ReLU')),
init_cfg=dict(
type='Pretrained',
checkpoint= # noqa: E251
'https://download.openmmlab.com/mmtracking/mot/reid/tracktor_reid_r50_iter25245-a452f51f.pth' # noqa: E501
)),
tracker=dict(
type='SortTracker',
obj_score_thr=0.5,
reid=dict(
num_samples=10,
img_scale=(256, 128),
img_norm_cfg=None,
match_score_thr=2.0),
match_iou_thr=0.5,
momentums=None,
num_tentatives=2,
num_frames_retain=100))
# learning policy
lr_config = dict(
policy='step',
warmup='linear',
warmup_iters=100,
warmup_ratio=1.0 / 100,
step=[3])
# runtime settings
total_epochs = 4
evaluation = dict(metric=['bbox', 'track'], interval=1)
search_metrics = ['MOTA', 'IDF1', 'FN', 'FP', 'IDs', 'MT', 'ML']