Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

OpenCV CUDA Python Bindings

Hello everyone,

I am writing a Python-based application using OpenCV and its Aruco module for marker detection. I want to parallelize some parts of the application, and noticed that the latest OpenCV build on GitHub seems to have many of the CUDA module functions wrapped with export macros.

CV_EXPORTS double threshold(InputArray src, OutputArray dst, double thresh, double maxval, int type, Stream& stream = Stream::Null());

It seems that I should be able to call this directly from my Python code, but I have not been able to do so (as far as I know).

Is it still necessary at this point to use some external library to link my Python code with the OpenCV CUDA code, e.g., PyCUDA?

Thanks!

OpenCV CUDA Python Bindings

Hello everyone,

I am writing a Python-based application using OpenCV and its Aruco module for marker detection. I want to parallelize some parts of the application, and noticed that the latest OpenCV build on GitHub seems to have many of the CUDA module functions wrapped with export macros.

CV_EXPORTS double threshold(InputArray src, OutputArray dst, double thresh, double maxval, int type, Stream& stream = Stream::Null());

It seems that I should be able to call this directly from my Python code, but I have not been able to do so (as far as I know).

Is it still necessary at this point to use some external library to link my Python code with the OpenCV CUDA code, e.g., PyCUDA?PyCUDA? Or am I already using the GPU implementation if I call cv2.threshold() if I've built OpenCV WITH_CUDA=ON?

Thanks!