You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Due to the check in _init_devicehere, ocl::OpenCLExecutionContext::create(Context&, Device&) requires that the device wrapper passed in (i.e. the Device, not just the cl_device_id) is one of the Devices in the Context.
This is not the case if the user does the following:
There is a prerequisite that ocl::Context should be created using the passed ocl::Device.
ocl::Device may have the same cl_device handler, but extra OpenCV-specific configuration may be different - e.g. used max work group size (for cases like #13108).
System information (version)
Detailed description
https://docs.opencv.org/4.5.2/d7/d83/classcv_1_1ocl_1_1OpenCLExecutionContext.html#a2890cfb4b198f7621590a2c0de4465fc
Due to the check in
_init_device
here,ocl::OpenCLExecutionContext::create(Context&, Device&)
requires that the device wrapper passed in (i.e. theDevice
, not just thecl_device_id
) is one of theDevice
s in theContext
.This is not the case if the user does the following:
Despite the underlying OpenCL device ids being the same:
The result is an exception:
Steps to reproduce
You can reproduce with a small modification to the reproduction here: #20518
Issue submission checklist
forum.opencv.org, Stack Overflow, etc and have not found solution
The text was updated successfully, but these errors were encountered: