-
Notifications
You must be signed in to change notification settings - Fork 64
Open
Description
遇到的问题:
如题,我尝试在一台旧电脑中实装该项目的时候,会一直报错
“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=torch.device('cpu') to map your storages to the CPU.”
即使我已经将“config”文件中的device调整为"cpu"也依旧产生。
临时解决方案:
在尝试将runtime/Lib/site-packages/torch/serialization.py中,1194行的location强制改为"cpu"后,可以跑通,并且生成成功(虽然速度很慢)
暂时不知道对整体的使用影响会不会很大,不知道大佬能不能出一个将config中的device赋值到全局的手段。
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels