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的序号 #3

Open
zkh123456789 opened this issue Sep 26, 2021 · 1 comment
Open

怎么控制GPU的序号 #3

zkh123456789 opened this issue Sep 26, 2021 · 1 comment

Comments

@zkh123456789
Copy link

作者您好,我想知道训练的时候怎么指定GPU的型号,每次我使用指令CUDA_VISIBLE_DEVICES=2,3这条指令的时候,似乎不管用,还是使用的默认的前两块GPU,请问您如何解决这个问题。

@CV-JunchengLi
Copy link
Contributor

在trainer.py加

import os

os.environ["CUDA_VISIBLE_DEVICES"] = "4,5"

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