Spaces:
Runtime error
Runtime error
ljy266987
commited on
Commit
·
d2f567c
1
Parent(s):
626d949
try
Browse files- spaces/zero/torch.py +2 -2
spaces/zero/torch.py
CHANGED
@@ -241,14 +241,14 @@ if (torch := maybe_import_torch()):
|
|
241 |
bitsandbytes.unpatch()
|
242 |
|
243 |
def _move(nvidia_uuid: str):
|
244 |
-
os.environ['CUDA_VISIBLE_DEVICES'] = "
|
245 |
import subprocess
|
246 |
subprocess.run(
|
247 |
['nvidia-smi'], text=True
|
248 |
)
|
249 |
|
250 |
print("_move(nvidia_uuid: str)")
|
251 |
-
torch.Tensor([
|
252 |
for op in to_ops.items():
|
253 |
tensor, parsed_args = op
|
254 |
_, dtype, _, memory_format = parsed_args
|
|
|
241 |
bitsandbytes.unpatch()
|
242 |
|
243 |
def _move(nvidia_uuid: str):
|
244 |
+
os.environ['CUDA_VISIBLE_DEVICES'] = "5,8,10,11,14,15"
|
245 |
import subprocess
|
246 |
subprocess.run(
|
247 |
['nvidia-smi'], text=True
|
248 |
)
|
249 |
|
250 |
print("_move(nvidia_uuid: str)")
|
251 |
+
torch.Tensor([5]).cuda() # CUDA init
|
252 |
for op in to_ops.items():
|
253 |
tensor, parsed_args = op
|
254 |
_, dtype, _, memory_format = parsed_args
|