Skip to content

Commit 1ca8242

Browse files
committed
fix
1 parent 94a194b commit 1ca8242

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

proxy.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,10 @@ def post(self, tool_name):
139139
num_gpus = subprocess.check_output(["nvidia-smi", "-L"]).decode().split("\n")
140140
num_gpus = [g.strip() for g in num_gpus]
141141
num_gpus = len([g for g in num_gpus if g.startswith("GPU ")])
142-
print(f"Detected {len(num_gpus)} GPUs.")
142+
print(f"Detected {num_gpus} GPUs.")
143143
cuda_devices_map = dict((i, i) for i in range(num_gpus))
144144

145-
num_to_launch = len(num_gpus) * num_per_gpu
145+
num_to_launch = num_gpus * num_per_gpu
146146
print(f"Will launch {num_to_launch} processes on GPUs.")
147147
set_cuda_visible_devices = True
148148

0 commit comments

Comments
 (0)