使用CPU加载报错

#16
by lanpangzi - opened

File "C:\Users\lanpangzi\AppData\Local\Programs\Python\Python39\lib\site-packages\torch\cuda_init_.py", line 284, in _lazy_init
raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled

modeling_minicpmo.py 第187行,删除.to("cuda")
vocos = Vocos(feature_extractor, backbone, head).eval().to(torch.float32)

OpenBMB org

你好,目前默认是需要 cuda 进行推理,如果希望改造成 cpu 推理可以把一些 gpu 操作删除或者转移到 cpu 计算

Sign up or log in to comment