RuntimeError: cuda runtime error (30) : unknown error at ..\aten\src\THC\THCGeneral.cpp:87
I have tried installing CUDA on Windows 10 to train nerual networks in my GPU(NVIDIA GeForce 710) but I get the following error when I tried to load an initial model.
Here's the code I am running:
device = torch.device(&quot;cuda&quot; if torch.cuda.is_available() else &quot;cpu&quot;)

device
&quot;&quot;&quot;# 1. Create the classifier&quot;&quot;&quot;

C = nn.Sequential(Flatten(), nn.Linear(784,200), nn.ReLU(), 
                            nn.Linear(200,100), nn.ReLU(),
                            nn.Linear(100,100), nn.ReLU(),
                            nn.Linear(100,10))

&quot;&quot;&quot;Upload the trained model&quot;&quot;&quot;

C.load_state_dict(torch.load(&quot;C.pt&quot;,map_location='cuda'))

And this is the error I am getting:
C.load_state_dict(torch.load(&quot;C.pt&quot;,map_location='cuda'))
Traceback (most recent call last):

  File &quot;&lt;ipython-input-2-358f76f483ed&gt;&quot;, line 1, in &lt;module&gt;
    C.load_state_dict(torch.load(&quot;C.pt&quot;,map_location='cuda'))

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 368, in load
    return _load(f, map_location, pickle_module)

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 542, in _load
    result = unpickler.load()

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 505, in persistent_load
    data_type(size), location)

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 385, in restore_location
    return default_restore_location(storage, map_location)

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 114, in default_restore_location
    result = fn(storage, location)

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\serialization.py&quot;, line 96, in _cuda_deserialize
    return obj.cuda(device)

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\_utils.py&quot;, line 68, in _cuda
    with torch.cuda.device(device):

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\cuda\__init__.py&quot;, line 229, in __enter__
    _lazy_init()

  File &quot;C:\Users\usuario\anaconda3\lib\site-packages\torch\cuda\__init__.py&quot;, line 162, in _lazy_init
    torch._C._cuda_init()

RuntimeError: cuda runtime error (30) : unknown error at ..\aten\src\THC\THCGeneral.cpp:87

I already installed cudNN and these are the versions I am using.
Python 3.7.6
CUDA 8.0
Pytorch 1.0.1

Restarting your computer might fix the issue
reference
if it doesn't make sure that you
Re-install latest GPU driver
Reboot
Ensure you have admin access
