We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 77ec968 commit cab00d0Copy full SHA for cab00d0
tests/test_uvm_tensor.py
@@ -7,6 +7,8 @@
7
8
# pyre-ignore-all-errors[56]
9
10
+import os
11
+
12
import pytest
13
import torch
14
from torchsnapshot.uvm_tensor import (
@@ -19,7 +21,12 @@
19
21
20
22
@pytest.mark.cpu_and_gpu
23
def test_uvm_tensor() -> None:
24
+ os.environ["CUDA_LAUNCH_BLOCKING"] = "1"
25
+ os.environ["TORCH_SHOW_CPP_STACKTRACES"] = "1"
26
if torch.cuda.is_available() and _UVM_TENSOR_AVAILABLE:
27
+ print("_UVM_TENSOR_AVAILABLE", _UVM_TENSOR_AVAILABLE)
28
+ print("torch.cuda.device_count(): ", torch.cuda.device_count())
29
+ print("torch.cuda.current_device(): ", torch.cuda.current_device())
30
uvm_tensor = torch.rand(
31
(64, 64),
32
out=new_managed_tensor(
0 commit comments