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

gpu problem brand #32

Open
Laz9999 opened this issue Aug 9, 2023 · 1 comment
Open

gpu problem brand #32

Laz9999 opened this issue Aug 9, 2023 · 1 comment

Comments

@Laz9999
Copy link

Laz9999 commented Aug 9, 2023

laz@DESKTOP-RQHN3N8:/mnt/c/Users/Laz/Desktop/Video-Pre-Training$ python3 run_agent.py --model 4x_idm.model --weights 4x_
idm.weights
---Loading model---
Traceback (most recent call last):
File "/mnt/c/Users/Laz/Desktop/Video-Pre-Training/run_agent.py", line 35, in
main(args.model, args.weights)
File "/mnt/c/Users/Laz/Desktop/Video-Pre-Training/run_agent.py", line 15, in main
agent = MineRLAgent(env, policy_kwargs=policy_kwargs, pi_head_kwargs=pi_head_kwargs)
File "/mnt/c/Users/Laz/Desktop/Video-Pre-Training/agent.py", line 128, in init
self.policy = MinecraftAgentPolicy(**agent_kwargs).to(device)
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1145, in to
return self._apply(convert)
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 797, in _apply
module._apply(fn)
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 797, in _apply
module._apply(fn)
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 797, in _apply
module._apply(fn)
[Previous line repeated 4 more times]
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 820, in _apply
param_applied = fn(param)
File "/home/laz/.local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1143, in convert
return t.to(device, dtype if t.is_floating_point() or t.is_complex() else None, non_blocking)
File "/home/laz/.local/lib/python3.10/site-packages/torch/cuda/init.py", line 247, in _lazy_init
torch._C._cuda_init()
RuntimeError: Found no NVIDIA driver on your system. Please check that you have an NVIDIA GPU and installed a driver from http://www.nvidia.com/Download/index.aspx
laz@DESKTOP-RQHN3N8:/mnt/c/Users/Laz/Desktop/Video-Pre-Training$

i want to ither use cpu or amd gpu

@Miffyli
Copy link
Collaborator

Miffyli commented Aug 9, 2023

Running on AMD GPUs has not been tested. You can change the code to use CPU by modifying this line to:

agent = MineRLAgent(env, policy_kwargs=policy_kwargs, pi_head_kwargs=pi_head_kwargs, device="cpu")

Note that this will be very slow to run.

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