首页 Paddle框架 帖子详情
maskrcnn测试报错
收藏
快速回复
Paddle框架 问答模型训练 552 3
maskrcnn测试报错
收藏
快速回复
Paddle框架 问答模型训练 552 3

maskrcnn测试报错

root@4ee0daf528e0:/workspace/work# python tools/eval.py -c configs/mask_rcnn/mask_rcnn_r50_fpn_1x_coco.yml -o weights=output/mask_rcnn_r50_fpn_1x_coco/model_final.pdparams
W0605 03:39:47.603252 1898 device_context.cc:404] Please NOTE: device: 0, GPU Compute Capability: 7.5, Driver API Version: 11.2, Runtime API Version: 10.1
W0605 03:39:47.605600 1898 device_context.cc:422] device: 0, cuDNN Version: 7.6.
loading annotations into memory...
Done (t=0.01s)
creating index...
index created!
[06/05 03:39:49] ppdet.utils.checkpoint INFO: Finish loading model weights: output/mask_rcnn_r50_fpn_1x_coco/model_final.pdparams
Traceback (most recent call last):
File "tools/eval.py", line 134, in
main()
File "tools/eval.py", line 130, in main
run(FLAGS, cfg)
File "tools/eval.py", line 105, in run
trainer.evaluate()
File "/usr/local/lib/python3.6/dist-packages/ppdet/engine/trainer.py", line 388, in evaluate
self._eval_with_loader(self.loader)
File "/usr/local/lib/python3.6/dist-packages/ppdet/engine/trainer.py", line 366, in _eval_with_loader
outs = self.model(data)
File "/usr/local/lib/python3.6/dist-packages/paddle/fluid/dygraph/layers.py", line 898, in __call__
outputs = self.forward(*inputs, **kwargs)
File "/usr/local/lib/python3.6/dist-packages/ppdet/modeling/architectures/meta_arch.py", line 29, in forward
out = self.get_pred()
File "/usr/local/lib/python3.6/dist-packages/ppdet/modeling/architectures/mask_rcnn.py", line 133, in get_pred
bbox_pred, bbox_num, mask_pred = self._forward()
File "/usr/local/lib/python3.6/dist-packages/ppdet/modeling/architectures/mask_rcnn.py", line 116, in _forward
im_shape, scale_factor)
File "/usr/local/lib/python3.6/dist-packages/ppdet/modeling/post_process.py", line 120, in get_pred
scaled_bbox = pred_bbox / scale_factor_list
File "/usr/local/lib/python3.6/dist-packages/paddle/fluid/dygraph/math_op_patch.py", line 250, in __impl__
return math_op(self, other_var, 'axis', axis)
RuntimeError: (PreconditionNotMet) The Tensor's element number must be equal or greater than zero. The Tensor's shape is [-1, 4] now
[Hint: Expected numel() >= 0, but received numel():-4 < 0:0.] (at /paddle/paddle/fluid/framework/tensor.cc:59)
[operator < elementwise_div > error]

0
收藏
回复
全部评论(3)
时间顺序
yghSTILL
#2 回复于2021-06

这个问题已修复,再使用最新的PaddleDetection代码试下呢:https://github.com/PaddlePaddle/PaddleDetection/tree/release/2.1

0
回复
s
sophiameihui
#3 回复于2021-06

我也遇到了同样的问题

0
回复
叫我光光哥哥丶
#4 回复于2021-08

你好,我也遇到了这个问题,请问该怎么解决呢(下载最新的代码没用)

0
回复
需求/bug反馈?一键提issue告诉我们
发现bug?如果您知道修复办法,欢迎提pr直接参与建设飞桨~
在@后输入用户全名并按空格结束,可艾特全站任一用户