KhronosGroup / OpenVX-cts

OpenVX Conformance Test Suite
Apache License 2.0
9 stars 6 forks source link

CTS DeconvolutionLayer reference code is incorrect #9

Open xzhan103 opened 4 years ago

xzhan103 commented 4 years ago

Issue1: test_conformance/test_tensor_nn.c line:2342:2343 if (x + w_x >= start_x_pad && x + w_x < input_w + start_x_pad && y + w_y >= start_y_pad && y + w_y < input_h + start_y_pad) The upper boundary is wrong. It should be changed as below if (x + w_x >= start_x_pad && x + w_x < input_w + start_x_pad + (upscale_x – 1) (input_w – 1) && y + w_y >= start_y_pad && y + w_y < input_h + start_y_pad + (upscale_y – 1) (input_h – 1))

Issue2: test_conformance/test_tensor_nn.c line:2337:2370 for (size_t ifm = 0; ifm < input_c; ++ifm) { for (size_t w_y = 0; w_y < weight_h; ++w_y) for (size_t w_x = 0; w_x < weight_w; ++w_x) { ....... sum = ownApplyWrapRoundingToAccum(fmt, i_val * w_val, wrap, to_ne) + sum;
} sum = ownWrapOrSat(fmt, sum, wrap); }

ownApplyWrapRoundingToAccum is misused. ownWrapOrSat is in wrong place.

Please help to check.