Support for Pool1d layer for OpenCV and OpenCL targets#18862
Support for Pool1d layer for OpenCV and OpenCL targets#18862alalek merged 8 commits intoopencv:3.4from
Conversation
|
@dkurt Can you please review the recent changes? |
| if (kernel_size.size() == 1) | ||
| return (backendId == DNN_BACKEND_OPENCV && preferableTarget == DNN_TARGET_CPU) || | ||
| (backendId == DNN_BACKEND_OPENCV && preferableTarget == DNN_TARGET_OPENCL) || | ||
| (backendId == DNN_BACKEND_OPENCV && preferableTarget == DNN_TARGET_OPENCL_FP16); |
There was a problem hiding this comment.
supportBackend(int backendId)
is not supposed to check preferableTarget value at all.
It is a design bug.
Caller doesn't expect failures for DNN_BACKEND_OPENCV.
/cc @dkurt
return backendId == DNN_BACKEND_OPENCV; should be enough here (replace these 3 lines).
There was a problem hiding this comment.
Actually, there is already else if (backendId == DNN_BACKEND_OPENCV || backendId == DNN_BACKEND_HALIDE) so this condition is always true
There was a problem hiding this comment.
It is false if backendId == DNN_BACKEND_HALIDE.
|
Please take a look at failed test: https://pullrequest.opencv.org/buildbot/builders/precommit_custom_mac/builds/1440. |
| if (kernel_size.size() == 1) | ||
| return (preferableTarget == DNN_TARGET_CPU || | ||
| preferableTarget == DNN_TARGET_OPENCL || | ||
| preferableTarget == DNN_TARGET_OPENCL_FP16); |
There was a problem hiding this comment.
Do we have other targets?
I just try to revert my changes to see why the tests broke. Everything was fine until I changed logic for support checks. See, for instance, https://pullrequest.opencv.org/buildbot/builders/precommit_custom_mac/builds/1438
54e86ee to
c9e85bc
Compare
c9e85bc to
c25988c
Compare
|
@alalek Do you know what is wrong with Cmake warnings on Mac? |
ignore, not related to this PR |
Resolves: #18643
Merge with extra: opencv/opencv_extra#820