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

How to use multiple GPUs? #11

Open
cenwangumass opened this issue Jan 19, 2024 · 0 comments
Open

How to use multiple GPUs? #11

cenwangumass opened this issue Jan 19, 2024 · 0 comments

Comments

@cenwangumass
Copy link

cenwangumass commented Jan 19, 2024

I have multiple GPUs on a machine and am trying to understand how to use them. In the C++ binding function execute I can see there is a line PjRtDevice *device = client->devices()[0]; which seems to always use the first available GPU. I tried to test changing 0 to 1, 2, etc., but am having the following error:

Execution of replica 0 failed: INVALID_ARGUMENT: Buffer passed to Execute() as argument 0 to replica 0 is on device gpu:3, but replica is assigned to device gpu:0.

Is there any suggestions how I should modified the code to use multiple GPUs? Thanks.

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

1 participant