首页 > 代码库 > cuda环境下安装opencv出现nvcc warning : The 'compute_11'
cuda环境下安装opencv出现nvcc warning : The 'compute_11'
警告打印:
- nvcc warning : The ‘compute_11‘, ‘compute_12‘, ‘compute_13‘, ‘sm_11‘, ‘sm_12‘, and ‘sm_13‘ architectures are deprecated, and may be removed in a future release.
找到cmake后产生的OpencvConfig.cmake文件,找到如下代码:
- # Version Compute Capability from which OpenCV has been compiled is remembered
- set(OpenCV_COMPUTE_CAPABILITIES -gencode;arch=compute_11,code=sm_11;-gencode;arch=compute_12,code=sm_12;-gencode;arch=compute_13,code=sm_13;-gencode;arch=compute_20,code=sm_20;-gencode;arch=compute_20,code=sm_21;-gencode;arch=compute_30,code=sm_30;-gencode;arch=compute_35,code=sm_35;-gencode;arch=compute_30,code=compute_30)
将"-gencode ;arch=compute_11,code=sm_11";-gencode;arch=compute_12,code=sm_12;-gencode;arch=compute_13,code=sm_13; 等删除。
主要因为此架构在CUDA过时~~将来也将不支持
以上若无果:
在cmakelist中关闭cuda~~
或者在cmake时加上参数-D BUILD_opencv_gpu=OFF
cuda环境下安装opencv出现nvcc warning : The 'compute_11'
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。