faster_rcnn_r101_fpn_1x预测数据生成问题
Created by: atczyh
https://github.com/PaddlePaddle/PaddleDetection/issues/165(转换的数据可成功在faster_rcnn_r50_1x训练的模型下进行预测),可是遇到了报错,错误如下:
我使用faster_rcnn_r101_fpn_1x训练了一只物体检测模型,使用了提问中已经通过的代码准备数据进行预测Error Message Summary:
Error: ShapeError: broadcast dimension mismatch. Operands could not be broadcast together with the shape of X = [1, 256, 47, 84] and the shape of Y = [1, 256, 48, 84]. Received [47] in X is not equal to [48] in Y [Hint: Expected y_dims[i] == 1, but received y_dims[i]:48 != 1:1.] at (/paddle/paddle/fluid/operators/elementwise/elementwise_op_function.h:79) [operator < elementwise_add > error] 使用官方的infer.py文件进行预测,没有遇到上述问题。于是将官方文件转换的数据进行了打印,发现im_info转换出来的参数与我的代码不一致: 本人代码转换出来的: 'im_info': array([[7.5000000e+02, 1.3330000e+03, 5.2070314e-01]]) 官方文件转换为 'im_info': array([[7.6800000e+02 1.3440000e+03 5.2070314e-01]]) 这就奇怪了,大家的图片参数都是一样的,为何官方文件转换得到的图片im_info会不一致的?
- !ResizeImage interp: 1 max_size: 1333 target_size: 800 use_cv2: true
- !NormalizeImage
is_channel_first: false
is_scale: true
mean:
- 0.485
- 0.456
- 0.406 std:
- 0.229
- 0.224
- 0.225 请高手指点,如何解决该问!