未验证 提交 9227e51c 编写于 作者: W whs 提交者: GitHub

Fix eval in pruning demo. (#687)

上级 0f79a355
......@@ -168,13 +168,23 @@ def main():
if 'weights' in cfg:
checkpoint.load_checkpoint(exe, eval_prog, cfg.weights)
results = eval_run(exe, compile_program, loader, keys, values, cls, cfg,
sub_eval_prog, sub_keys, sub_values)
# evaluation
resolution = None
if 'mask' in results[0]:
if 'Mask' in cfg.architecture:
resolution = model.mask_head.resolution
results = eval_run(
exe,
compile_program,
loader,
keys,
values,
cls,
cfg,
sub_eval_prog,
sub_keys,
sub_values,
resolution=resolution)
# if map_type not set, use default 11point, only use in VOC eval
map_type = cfg.map_type if 'map_type' in cfg else '11point'
eval_results(
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册