Closed Christywl closed 5 years ago
The data on WebGL backend for with/out align corner:
Test Case | expected results | w/o align_corner | w/align_corner |
---|---|---|---|
check result for Resize bilinear example | [1.0, 1.0, 1.0, 1.666666667, 1.666666667, 1.666666667, 2.0, 2.0, 2.0] | [1.0, 1.0, 1.0, 1.666666667, 1.666666667, 1.666666667, 2.0, 2.0, 2.0] | [1, 1, 1, 1.5, 1.5, 1.5, 2, 2, 2] |
check result for Resize bilinear example/2 | [3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16] | [3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16] | [3, 4, 4.5, 7, 6, 10, 6, 7, 7.5, 10, 9, 13, 9, 10, 10.5, 13, 12, 16] |
check result for Resize bilinear distorted example/1 | [3, 4, 4.5, 7, 6, 10, 6, 10, 7, 8, 8.5, 11, 10, 14, 10, 14, 9, 10, 10.5, 13, 12, 16, 12, 16, 3, 4, 4.5, 7, 6, 10, 6, 10, 7, 8, 8.5, 11, 10, 14, 10, 14, 9, 10, 10.5, 13, 12, 16, 12, 16] | [3, 4, 4.5, 7, 6, 10, 6, 10, 7, 8, 8.5, 11, 10, 14, 10, 14, 9, 10, 10.5, 13, 12, 16, 12, 16, 3, 4, 4.5, 7, 6, 10, 6, 10, 7, 8, 8.5, 11, 10, 14, 10, 14, 9, 10, 10.5, 13, 12, 16, 12, 16] | [3, 4, 4, 6, 5, 8, 6, 10, 6, 7, 7, 9, 8, 11, 9, 13, 9, 10, 10, 12, 11, 14, 12, 16, 3, 4, 4, 6, 5, 8, 6, 10, 6, 7, 7, 9, 8, 11, 9, 13, 9, 10, 10, 12, 11, 14, 12, 16] |
check result for Resize bilinear distorted example/2 | [1, 3, 9, 11, 13, 15, 9, 11, 1, 3, 9, 11, 13, 15, 9, 11] | [1, 3, 9, 11, 13, 15, 9, 11, 1, 3, 9, 11, 13, 15, 9, 11] | [1, 3, 13, 15, 9, 11, 21, 23, 1, 3, 13, 15, 9, 11, 21, 23] |
check result for Resize bilinear distorted example/3 | [1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667] | [1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667,1, 3, 6.3333335, 8.333334, 11.666667, 13.666667] | [1, 3, 7, 9, 13, 15, 1, 3, 7, 9, 13, 15, 1, 3, 7, 9, 13, 15, 1, 3, 7, 9, 13, 15, 1, 3, 7, 9, 13, 15, 1, 3, 7, 9, 13, 15] |
check result for Resize bilinear distorted example/4 | [1, 3, 3.6666667, 5.666667, 5, 7, 6.333333, 8.333333, 9, 11, 10.333333, 12.333333, 6.333334, 8.333334, 9.000001, 11.000001, 10.333334, 12.333334, 1, 3, 3.6666667, 5.666667, 5, 7, 6.333333, 8.333333, 9, 11, 10.333333, 12.333333, 6.333334, 8.333334, 9.000001, 11.000001, 10.333334, 12.333334] | [1, 3, 3.6666667, 5.666667, 5, 7, 6.333333, 8.333333, 9, 11, 10.333333, 12.333333, 6.333334, 8.333334, 9.000001, 11.000001, 10.333334, 12.333334, 1, 3, 3.6666667, 5.666667, 5, 7, 6.333333, 8.333333, 9, 11, 10.333333, 12.333333, 6.333334, 8.333334, 9.000001, 11.000001, 10.333334, 12.333334] | [1, 3, 3, 5, 5, 7, 5, 7, 7, 9, 9, 11, 9, 11, 11, 13, 13, 15, 1, 3, 3, 5, 5, 7, 5, 7, 7, 9, 9, 11, 9, 11, 11, 13, 13, 15] |
check result for Resize bilinear remain size example/1 | [1, 1, 2, 2] | [1, 1, 2, 2] | [1, 1, 2, 2] |
check result for Resize bilinear remain size example/2 | [1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2] |
check result for Resize bilinear remain size example/3 | [1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2] |
check result for Resize bilinear remain size example/4 | [1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2] | [1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 2, 2] |
check result for Resize bilinear zoom in example/1 | [3, 3.6666667, 4, 5, 7, 8, 6, 8.6666667, 10, 9, 9.6666667, 10, 11, 13, 14, 12, 14.6666667, 16] | [3, 3.6666667, 4, 5, 7, 8, 6, 8.6666667, 10, 9, 9.6666667, 10, 11, 13, 14, 12, 14.6666667, 16] | [3, 3.5, 4, 4.5, 5.75, 7, 6, 8, 10, 9, 9.5, 10, 10.5, 11.75, 13, 12, 14, 16] |
check result for Resize bilinear zoom in example/2 | [3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16, 3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16] | [3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16, 3, 4, 5, 8, 6, 10, 7, 8, 9, 12, 10, 14, 9, 10, 11, 14, 12, 16] | [3, 4, 4.5, 7, 6, 10, 6, 7, 7.5, 10, 9, 13, 9, 10, 10.5, 13, 12, 16, 3, 4, 4.5, 7, 6, 10, 6, 7, 7.5, 10, 9, 13, 9, 10, 10.5, 13, 12, 16] |
check result for Resize bilinear zoom out example/1 | [1, 4, 10, 13] | [1, 4, 10, 13] | [1, 5, 13, 17] |
check result for Resize bilinear zoom out example/2 | [1, 4, 10, 13, 1, 4, 10, 13] | [1, 4, 10, 13, 1, 4, 10, 13] | [1, 5, 13, 17, 1, 5, 13, 17] |
check result for Resize bilinear zoom out example/3 | [1, 3, 7, 9, 10, 12, 11.5, 9] | [1, 3, 7, 9, 10, 12, 11.5, 9] | [1, 3, 9, 11, 7, 9, 15, 17] |
check result for Resize bilinear zoom out example/4 | [1, 3, 7, 9, 10, 12, 11.5, 9, 1, 3, 7, 9, 10, 12, 11.5, 9] | [1, 3, 7, 9, 10, 12, 11.5, 9, 1, 3, 7, 9, 10, 12, 11.5, 9] | [1, 3, 9, 11, 7, 9, 15, 17, 1, 3, 9, 11, 7, 9, 15, 17] |
WASM and clDNN also enable align_corner, the data with align_corner is the same as WebGL.
Test Env: Chromium nightly build 70.0.3503.0 (8755e6b) Platform: Android/Mac/Windows/Linux
Expected Result: Tests should pass.
Actual Result: The tests failed after align_corner(https://github.com/intel/webml-polyfill/commit/b4fb43aeb474f2724c138c1ea308eefb2f5e255c) was supported in RESIZE_BILINEAR on WebGL backend.
How to Reproduce: