CSAILVision / CSAILVision/IBD

How to run on machine without a GPU

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
52
Forks
13
PR merge metrics
No merged PRs in 30d

Description

Hi,
I was wondering how can I run this on a machine that does not have the GPU? Also here is the settings that it is currently running. Also I tried looking online but wasn't able to make it work.

Thanks,
Joshua

######### global settings #########
GPU = False

Here's the error I am getting.

Traceback (most recent call last):
File "test.py", line 22, in
model = loadmodel()
File "/home/joshuayun/Desktop/IBD/loader/model_loader.py", line 44, in loadmodel
checkpoint = torch.load(settings.MODEL_FILE)
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 387, in load
return _load(f, map_location, pickle_module, **pickle_load_args)
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 574, in _load
result = unpickler.load()
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 537, in persistent_load
deserialized_objects[root_key] = restore_location(obj, location)
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 119, in default_restore_location
result = fn(storage, location)
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 95, in _cuda_deserialize
device = validate_cuda_device(location)
File "/home/joshuayun/.local/lib/python3.6/site-packages/torch/serialization.py", line 79, in validate_cuda_device
raise RuntimeError('Attempting to deserialize object on a CUDA '
RuntimeError: Attempting to deserialize object on a CUDA device but torch.cuda.is_available() is False. If you are running on a CPU-only machine, please use torch.load with map_location='cpu' to map your storages to the CPU.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.