I use TX1 board with L4T 28.1
I compile opencv on the board with DWITH_CUDA=ON with cuda 8 toolkit
I try to use opencv functions, which use gpu. I try to declare GpuMat
GpuMat TestGpuMat(480, 640, CV_16UC1, 0x55);
and get Segmentation fault during runtime in module cv::cuda::GpuMat::create().
I can allocate the same matrix if I provide the allocated memory before
CudaMallocManaged((void**)MyBuf, 640*480*sizeof(unsigned short)); GpuMat TestGpuMat(480, 640, CV_16UC1, MyBuf)
In that case I receive the fault in cuda::warpAffine function
OpenCVError: Gpu API call (invalid argument) in setTo
What is a reason for that behavior and what is solution?