使用MOT评测工具TrackEval评测自己的数据集

TrackEval使用教程

可以看这个博主写的,很详细https://zhuanlan.zhihu.com/p/391396206

制作自己的MOT数据集

软件推荐

这里我推荐使用Darklabel,如果进不去的话,我上传到百度云,供大家下载使用。链接:

链接:https://pan.baidu.com/s/1K7vWRWr6jzi6xFSfAxwhVA
提取码:phu

1.打开yaml文件,将自己要跟踪的类别写进去,这里我的类别是下面这几类

my_classes: ["uav", "car", "person"]

2.相关讲解,不过现在版本快捷键是shift+鼠标操作了。
制作好相关数据集之后,跟踪完成保存结果。使用TrackEval进行评估。
我们的数据集的格式如下:

1,1,592,444,482,284,1,-1,-1,-1

命名为gt.txt

文件路径

#gt信息
#如果多个的话,并列存放
data/
    gt/
        mot_challenge/
            MyDataset/
                seq-01/   # 视频名
                    gt/
                        gt.txt          # <---- ground truth
                    seqinfo.ini         # 放你的视频的信息
    trackers/   # 你自己代码运行出来的结果
        mot_challenge/
            MyDataset/
                data/
                    seq-01.txt          # <---- model result 视频结果.txt

seqinfo.ini的信息

[Sequence]
name=ai_city
imDir=img1
frameRate=30
seqLength=1996
imWidth=1920
imHeight=1080
imExt=.jpg

运行

运行 scripts/run_mot_challenge.py

-GT_FOLDER # gt路径
--BENCHMARK ai_city   # 视频名
--DO_PREPROC False 
--METRICS HOTA # 选择测评指标 'HOTA', 'CLEAR', 'Identity'

这里附上我自己跑出来的结果,因为我用的两个都是gt.txt

CLEAR: data-pedestrian             MOTA      MOTP      MODA      CLR_Re    CLR_Pr    MTR       PTR       MLR       sMOTA     CLR_TP    CLR_FN    CLR_FP    IDSW      MT        PT        ML        Frag      
more_2_0                           100       100       100       100       100       100       0         0         100       1056      0         0         0         4         0         0         0         
more_2_1                           100       100       100       100       100       100       0         0         100       1065      0         0         0         5         0         0         0         
more_2_2                           100       100       100       100       100       100       0         0         100       476       0         0         0         2         0         0         0         
more_2_3                           100       100       100       100       100       100       0         0         100       971       0         0         0         4         0         0         0         
COMBINED                           100       100       100       100       100       100       0         0         100       3568      0         0         0         15        0         0         0         

Count: data-pedestrian             Dets      GT_Dets   IDs       GT_IDs    
more_2_0                           1056      1056      4         4         
more_2_1                           1065      1065      5         5         
more_2_2                           476       476       2         2         
more_2_3                           971       971       4         4         
COMBINED                           3568      3568      15        15   

后续发现的bug

重新在测评的时候,出现了下面这个问题,评论区也有人遇到了,看问题的报错是因为类别不对,因此,需要修改gt文件中的类别,我们在使用Darklabel标注结束后,gt文件的格式是:

1,1,592,444,482,284,-1,-1,-1,-1

我们需要将其修改为

1,1,592,444,482,284,-1,1,-1,-1

最后我的测试通过。

trackeval.utils.TrackEvalException: Attempting to evaluate using invalid gt classes. This warning only triggers if preprocessing is performed, e.g. not for MOT15 or where prepropressing is explicitly disabled. Please either check your gt data, or disable preprocessing. The following invalid classes were found in timestep 1: -1

猜你喜欢

转载自blog.csdn.net/gubeiqing/article/details/123648141
今日推荐