I have configured the environment as required, but I still get a CUDA error when running pretrain.py, why?
Environment:
python 3.6
torch 1.6.0+cu101
dgl-cu101 0.4.3
CUDA 10.1
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Sun_Jul_28_19:07:16_PDT_2019
Cuda compilation tools, release 10.1, V10.1.243
Traceback (most recent call last):
File "pretrain.py", line 139, in
train(args)
File "pretrain.py", line 51, in train
model.cuda()
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/module.py", line 458, in cuda
return self._apply(lambda t: t.cuda(device))
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/module.py", line 354, in _apply
module._apply(fn)
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/rnn.py", line 161, in _apply
self.flatten_parameters()
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/rnn.py", line 151, in flatten_parameters
self.batch_first, bool(self.bidirectional))
RuntimeError: CUDA error: no kernel image is available for execution on the device
I have configured the environment as required, but I still get a CUDA error when running pretrain.py, why?
Environment: python 3.6 torch 1.6.0+cu101 dgl-cu101 0.4.3 CUDA 10.1 nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2019 NVIDIA Corporation Built on Sun_Jul_28_19:07:16_PDT_2019 Cuda compilation tools, release 10.1, V10.1.243
Traceback (most recent call last): File "pretrain.py", line 139, in
train(args)
File "pretrain.py", line 51, in train
model.cuda()
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/module.py", line 458, in cuda
return self._apply(lambda t: t.cuda(device))
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/module.py", line 354, in _apply
module._apply(fn)
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/rnn.py", line 161, in _apply
self.flatten_parameters()
File "/home/sitiange/miniconda3/envs/renet/lib/python3.6/site-packages/torch/nn/modules/rnn.py", line 151, in flatten_parameters
self.batch_first, bool(self.bidirectional))
RuntimeError: CUDA error: no kernel image is available for execution on the device