pytorch terminate called after throwing an instance of ‘c10::HIPError‘
pytorch terminate called after throwing an instance of ‘c10::HIPError‘
今天在跑PPO程序的时候,出现了下面的错误:
terminate called after throwing an instance of 'c10::HIPError' what(): HIP error: hipErrorNoDeviceHIP kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect.For debugging consider passing HIP_LAUNCH_BLOCKING=1.Exception raised from deviceCount at /pytorch/aten/src/ATen/hip/impl/HIPGuardImplMasqueradingAsCUDA.h:102 (most recent call first):frame #0: c10::Error::Error(c10::SourceLocation, std::string) + 0x42 (0x7f839e38ec72 in /root/anaconda3/lib/python3.7/site-packages/torch/lib/libc10.so)frame #1:
我的torch版本是:
torch 1.11.0+rocm4.5.2cuda 10.2
解决方法
回退torch版本到1.5
pip install torch==1.5
然后就可以运行了。
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。
发表评论
暂时没有评论,来抢沙发吧~