Is it possible to access CuPy array/memory directly within cuda_GpuMat to support CudaArrayInterface?
Implemented a wrapper of CudaArrayInterface works fine to move GpuMat memory directly to CuPy. However, it failed with moving from CuPy array to GpuMat.
Reference below link
if initiated cuda_GpuMat with CuPy array pointer, the result is not as expected, it seems cv2.cuda_GpuMat calls some default allocator and does not use the passed pointer memory.
img_cv2_cu = cv2.cuda_GpuMat(img_cp.cuda_array_interface[‘shape’],
cv2.CV_8U, # or cv2.CV_8UC1
Is there anyone can help to check this ? any guidance on how to do this?