RuntimeError: Deterministic behavior was enabled with either `torch.use_deterministic_algorithms(True)` or `at::Context::setDeterministicAlgorithms(true)`,

在CORL的代码中,出现了一种error:

 

 可经过如下方法解决:

cuda 10.1

os.environ['CUDA_LAUNCH_BLOCKING'] = '1'

cuda 10.2及以上
os.environ['CUBLAS_WORKSPACE_CONFIG']=':16:8'       
os.environ['CUBLAS_WORKSPACE_CONFIG']=':4096:2'

参考:
https://neusncp.com/user/blog?id=766
posted @ 2022-10-23 22:51  呦呦南山  阅读(1600)  评论(0编辑  收藏  举报