2021CVPR-ReDet代码调试


概要:编译ops里面代码的时候,出现了RuntimeError: Error compiling objects for extension 这样的错误提示


问题分析:在网上查看了很多资料,感觉都不适合我的情况。后来查看作者的INSTALL.md文档,发现 pytorch版本限定在了1.1和1.3.1,而我的pytorch版本为1.71!而且作者指出了

Note:

  1. If you want to use Pytorch>1.5, you have to made some modifications to the cuda ops. See here for a reference.
  2. There is a known bug happened to some users but not all (As I have successfully run it on V100 and Titan Xp). If it occurs, please refer to here.
  3. If you want to use Python<=3.6, you need to install e2cnn@legacy_py3.6 mamually, see here for an instruction.

即:如果是1.5以上版本,需要修改 cuda ops.具体为:

AT_CHECK with TORCH_CHECK in the source code (.cpp and .cu).
把所有cpp和cu里的AT_CHECK替换为TORCH_CHECK​​​​​​​

查看INSTALL.md文档很重要!
查看INSTALL.md文档很重要!
查看INSTALL.md文档很重要!
重要的事情说三遍!

 

 

 

  • 3
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 15
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 15
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值