Skip to content

Commit b03e75f

Browse files
committed
Move cuda runtime error to end
1 parent ba37e4e commit b03e75f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/smoke_test/smoke_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ def cuda_runtime_error():
7272
def smoke_test_cuda(package: str) -> None:
7373
if not torch.cuda.is_available() and is_cuda_system:
7474
raise RuntimeError(f"Expected CUDA {gpu_arch_ver}. However CUDA is not loaded.")
75-
75+
if torch.cuda.is_available():
7676
if torch.version.cuda != gpu_arch_ver:
7777
raise RuntimeError(
7878
f"Wrong CUDA version. Loaded: {torch.version.cuda} Expected: {gpu_arch_ver}"

0 commit comments

Comments
 (0)