未验证 提交 93a42f3c 编写于 作者: W whs 提交者: GitHub

Fix eval_run in pruning script (#726)

上级 a23b9c42
...@@ -307,6 +307,9 @@ def main(): ...@@ -307,6 +307,9 @@ def main():
if FLAGS.eval: if FLAGS.eval:
# evaluation # evaluation
resolution = None
if 'Mask' in cfg.architecture:
resolution = model.mask_head.resolution
results = eval_run( results = eval_run(
exe, exe,
compiled_eval_prog, compiled_eval_prog,
...@@ -314,10 +317,8 @@ def main(): ...@@ -314,10 +317,8 @@ def main():
eval_keys, eval_keys,
eval_values, eval_values,
eval_cls, eval_cls,
cfg=cfg) cfg=cfg,
resolution = None resolution=resolution)
if 'mask' in results[0]:
resolution = model.mask_head.resolution
box_ap_stats = eval_results( box_ap_stats = eval_results(
results, results,
cfg.metric, cfg.metric,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册