Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
detr_pytorch
Commits
22caa57c
Commit
22caa57c
authored
Feb 22, 2024
by
Rayyyyy
Browse files
Fix bug in test.py
parent
042ea171
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
README.md
README.md
+1
-1
test.py
test.py
+1
-1
No files found.
README.md
View file @
22caa57c
...
...
@@ -102,7 +102,7 @@ bash train.sh
## 推理
验证前需提前准备好预训练模型, 可从
参考资料
中提供的模型下载, 并将coco_path设置为当前环境中推理数据的对应地址, 数据应为COCO数据格式。
验证前需提前准备好预训练模型, 可从
最下面的
**参考资料**
项目
中提供的模型下载, 并将coco_path设置为当前环境中推理数据的对应地址, 数据应为COCO数据格式。
如果想要查看预测效果(预测结果输出到图片上), 请执行(其余参数如backbone等需与训练模型参数需一致, 详情请根据训练参数配置):
...
...
test.py
View file @
22caa57c
...
...
@@ -116,7 +116,7 @@ if __name__ == "__main__":
device
=
torch
.
device
(
args
.
device
)
if
not
os
.
path
.
exists
(
args
.
save_path
):
os
.
makedirs
()
os
.
makedirs
(
args
.
save_path
)
model
,
postprocessors
=
build_test_model
(
args
)
model
.
to
(
device
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment