Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
s920243400
PaddleDetection
提交
2e97f197
P
PaddleDetection
项目概览
s920243400
/
PaddleDetection
与 Fork 源项目一致
Fork自
PaddlePaddle / PaddleDetection
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
PaddleDetection
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
2e97f197
编写于
5月 18, 2021
作者:
G
George Ni
提交者:
GitHub
5月 18, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[MOT] Fix mot source (#3061)
* fix mot_source * fix mot_source, test=document_fix
上级
2b7a999d
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
5 addition
and
24 deletion
+5
-24
configs/datasets/mot.yml
configs/datasets/mot.yml
+4
-2
ppdet/data/source/mot.py
ppdet/data/source/mot.py
+0
-22
ppdet/data/transform/mot_operators.py
ppdet/data/transform/mot_operators.py
+1
-0
未找到文件。
configs/datasets/mot.yml
浏览文件 @
2e97f197
...
@@ -19,13 +19,15 @@ TrainDataset:
...
@@ -19,13 +19,15 @@ TrainDataset:
image_lists
:
[
'
mot17.train'
,
'
caltech.all'
,
'
cuhksysu.train'
,
'
prw.train'
,
'
citypersons.train'
,
'
eth.train'
]
image_lists
:
[
'
mot17.train'
,
'
caltech.all'
,
'
cuhksysu.train'
,
'
prw.train'
,
'
citypersons.train'
,
'
eth.train'
]
data_fields
:
[
'
image'
,
'
gt_bbox'
,
'
gt_class'
,
'
gt_ide'
]
data_fields
:
[
'
image'
,
'
gt_bbox'
,
'
gt_class'
,
'
gt_ide'
]
# for detection or reid evaluation, no use in MOT evaluation
EvalDataset
:
EvalDataset
:
!MOTDataSet
!MOTDataSet
dataset_dir
:
dataset/mot
dataset_dir
:
dataset/mot
image_lists
:
[
'
citypersons.val'
,
'
caltech.val'
]
# for detection
image_lists
:
[
'
citypersons.val'
,
'
caltech.val'
]
# for detection
evaluation
# image_lists: ['caltech.10k.val', 'cuhksysu.val', 'prw.val'] # for reid
# image_lists: ['caltech.10k.val', 'cuhksysu.val', 'prw.val'] # for reid
evaluation
data_fields
:
[
'
image'
,
'
gt_bbox'
,
'
gt_class'
,
'
gt_ide'
]
data_fields
:
[
'
image'
,
'
gt_bbox'
,
'
gt_class'
,
'
gt_ide'
]
# for detection inference, no use in MOT inference
TestDataset
:
TestDataset
:
!ImageFolder
!ImageFolder
dataset_dir
:
dataset/mot
dataset_dir
:
dataset/mot
...
...
ppdet/data/source/mot.py
浏览文件 @
2e97f197
...
@@ -124,28 +124,6 @@ class MOTDataSet(DetDataset):
...
@@ -124,28 +124,6 @@ class MOTDataSet(DetDataset):
self
.
img_start_index
[
data_name
]
=
img_index
self
.
img_start_index
[
data_name
]
=
img_index
img_index
+=
len
(
self
.
img_files
[
data_name
])
img_index
+=
len
(
self
.
img_files
[
data_name
])
# check data directory, images and labels_with_ids
if
len
(
self
.
img_files
[
data_name
])
==
0
:
continue
else
:
# self.img_files[data_name] each line following this:
# {self.dataset_dir}/MOT17/images/...
first_path
=
self
.
img_files
[
data_name
][
0
]
data_dir
=
first_path
.
replace
(
self
.
dataset_dir
,
''
).
split
(
'/'
)[
1
]
data_dir
=
os
.
path
.
join
(
self
.
dataset_dir
,
data_dir
)
assert
os
.
path
.
exists
(
data_dir
),
\
"The data directory {} does not exist."
.
format
(
data_dir
)
data_dir_images
=
os
.
path
.
join
(
data_dir
,
'images'
)
assert
os
.
path
.
exists
(
data_dir
),
\
"The data images directory {} does not exist."
.
format
(
data_dir_images
)
data_dir_labels_with_ids
=
os
.
path
.
join
(
data_dir
,
'labels_with_ids'
)
assert
os
.
path
.
exists
(
data_dir
),
\
"The data labels directory {} does not exist."
.
format
(
data_dir_labels_with_ids
)
# record label_files
# record label_files
self
.
label_files
[
data_name
]
=
[
self
.
label_files
[
data_name
]
=
[
x
.
replace
(
'images'
,
'labels_with_ids'
).
replace
(
x
.
replace
(
'images'
,
'labels_with_ids'
).
replace
(
...
...
ppdet/data/transform/mot_operators.py
浏览文件 @
2e97f197
...
@@ -25,6 +25,7 @@ from numbers import Integral
...
@@ -25,6 +25,7 @@ from numbers import Integral
import
cv2
import
cv2
import
copy
import
copy
import
numpy
as
np
import
numpy
as
np
import
random
import
math
import
math
from
.operators
import
BaseOperator
,
register_op
from
.operators
import
BaseOperator
,
register_op
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录