エラー内容
TypeError: Layout of the output array img is incompatible with cv::Mat (step[ndims-1] != elemsize or step[1] != elemsize*nchannels)
対策
image = np.ascontiguousarray(image, dtype=np.uint8)
エラー内容
TypeError: Layout of the output array img is incompatible with cv::Mat (step[ndims-1] != elemsize or step[1] != elemsize*nchannels)
対策
image = np.ascontiguousarray(image, dtype=np.uint8)