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

os.environ['CUDA_VISIBLE_DEVICES'] = '1' does not work in jupyter #571

Closed
imhuay opened this issue Jul 25, 2023 · 1 comment
Closed

os.environ['CUDA_VISIBLE_DEVICES'] = '1' does not work in jupyter #571

imhuay opened this issue Jul 25, 2023 · 1 comment

Comments

@imhuay
Copy link

imhuay commented Jul 25, 2023

As the title says, it is invalid to specify the GPU through CUDA_VISIBLE_DEVICES in jupyter, and only 'GPU:0' will still be used; but it is effective when using CUDA_VISIBLE_DEVICES=1 python *.py

@zhuohan123
Copy link
Member

Did you set CUDA_VISIBLE_DEVICES before you import any vLLM/Pytorch/Ray related packages? Maybe it's because you set the environment variable too late so it will not be effective.

@imhuay imhuay closed this as completed Aug 8, 2023
rickyyx pushed a commit to rickyyx/vllm that referenced this issue Oct 7, 2024
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