Unverified Commit beb4bb70 authored by Omkar Salpekar's avatar Omkar Salpekar Committed by GitHub
Browse files

Fix failing smoke test (#7388)

parent 5d9bc5e5
"""Run smoke tests""" """Run smoke tests"""
import os import os
import sys
from pathlib import Path from pathlib import Path
from sys import platform
import torch import torch
import torch.nn as nn import torch.nn as nn
...@@ -37,7 +37,7 @@ def smoke_test_compile() -> None: ...@@ -37,7 +37,7 @@ def smoke_test_compile() -> None:
out = model(x) out = model(x)
print(f"torch.compile model output: {out.shape}") print(f"torch.compile model output: {out.shape}")
except RuntimeError: except RuntimeError:
if platform == "win32": if sys.platform == "win32":
print("Successfully caught torch.compile RuntimeError on win") print("Successfully caught torch.compile RuntimeError on win")
elif sys.version_info >= (3, 11, 0): elif sys.version_info >= (3, 11, 0):
print("Successfully caught torch.compile RuntimeError on Python 3.11") print("Successfully caught torch.compile RuntimeError on Python 3.11")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment