Skip to content

Commit

Permalink
fix the start gpu bug (deepjavalibrary#709)
Browse files Browse the repository at this point in the history
  • Loading branch information
Qing Lan authored May 12, 2023
1 parent c8cbc0e commit a583888
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ private static String getVisibleDevices(int workerId, int tensorParallelDegree)
// -> 0,2 and 3,7
if (Utils.getenv("CUDA_VISIBLE_DEVICES") != null) {
String[] devices = Utils.getenv("CUDA_VISIBLE_DEVICES").split(",");
sb.append(devices[tensorParallelDegree]);
sb.append(devices[workerId * tensorParallelDegree]);
for (int i = 1; i < tensorParallelDegree; ++i) {
sb.append(',').append(devices[workerId * tensorParallelDegree + i]);
}
Expand Down

0 comments on commit a583888

Please sign in to comment.