Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GSoC] GPU device is not detected inside openvino environment #949

Closed
Nouran-Muhammad opened this issue Mar 24, 2023 · 2 comments
Closed

Comments

@Nouran-Muhammad
Copy link

Hello,
I have been working on the prerequisite task on ESPNet. I am working inside a virtual environment for openvino. I cloned the model's repo and I am trying to run inference using the pytorch version of the model where i call a script written by the authors for inference, but it gives me the following error:
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.

Outside openvino environment, CUDA is detetcted while inside openvino env it is not. I installed all the requirements and followed the instructions for installation in anaconda. I tried a lot with different versions for torch.
Can someone tell me what to do?
Thanks

@eaidova
Copy link
Contributor

eaidova commented Mar 27, 2023

@Nouran-Muhammad please try to load model on CPU instead. We can not use nvidia GPU in openvino environment because not all users can have this hardware, also installing torch without GPU support significantly reduce the memory required for installing package.
The solution which you need to use is already provided in your error message:
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., please add this parameter

@Nouran-Muhammad
Copy link
Author

Thank you for your reply.
I know i can add this parameter to work on the CPU, but i thought i should use GPU in the notebook.
Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants