Skip to content

Commit 88f0062

Browse files
committed
Update on "Added symbolic shape testing for AOTAutograd"
[ghstack-poisoned]
1 parent c82ac25 commit 88f0062

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

functorch/test/test_aotdispatch.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,13 @@
5656
warnings.warn("Some tests use networkx but it was not installed",
5757
UserWarning)
5858

59+
try:
60+
import sympy # noqa: F401
61+
HAS_SYMPY = True
62+
except ImportError:
63+
HAS_SYMPY = False
64+
skipIfNoSympy = unittest.skipIf(not HAS_SYMPY, "no sympy")
65+
5966
# NB: numpy is a testing dependency!
6067

6168
class AOTTestCase(TestCase):
@@ -1135,6 +1142,7 @@ def test_aot_autograd_exhaustive(self, device, dtype, op):
11351142
_test_aot_autograd_helper(self, device, dtype, op)
11361143

11371144
@ops(op_db, allowed_dtypes=(torch.float,))
1145+
@skipIfNoSympy
11381146
@patch("functorch.compile.config.use_dynamic_shapes", True)
11391147
@patch("functorch.compile.config.use_fake_tensor", True)
11401148
@patch("functorch.compile.config.use_functionalize", False)

0 commit comments

Comments
 (0)