Turn on type-checking in torch.fx.experimental.symbolic_shapes#136972
Turn on type-checking in torch.fx.experimental.symbolic_shapes#136972ezyang wants to merge 4 commits intogh/ezyang/2948/basefrom
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/136972
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 147 PendingAs of commit ca05599 with merge base failed to retrieve merge base, please contact dev infra: This comment was automatically generated by Dr. CI and updates every 15 minutes. |
| assert arg.fake_tensor is not None | ||
|
|
||
| def bind_symint(s, prop): | ||
| def bind_symint(s: torch.SymInt, prop): |
There was a problem hiding this comment.
nit specify return type
There was a problem hiding this comment.
There are actually a lot of untyped defs, I'm working on them in the next PR in stack
| and raw_u1.args[0][0] == 1 | ||
| and isinstance(eq := raw_u1.args[0][1], sympy.Eq) | ||
| and ( | ||
| raw_u1_args0 := cast( |
There was a problem hiding this comment.
We need casting? We can't just specify the type here before the walrus op?
There was a problem hiding this comment.
Unfortunately, sympy annotates the type of args as Sequence[sympy.Basic], so the type annotation of args[0] is Basic when it needs to be a Tuple (because Piecewise). So even if we specified the type in walrus we would need to also do a mypy ignore.
|
@pytorchbot merge -i |
Merge startedYour change will be merged while ignoring the following 1 checks: Lint / Test Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Merge failedReason: 1 jobs have failed, first few of them are: inductor-periodic / cuda12.1-py3.10-gcc9-sm80 / test (inductor_torchbench_smoketest_perf, 1, 1, linux.gcp.a100) Details for Dev Infra teamRaised by workflow job |
|
@pytorchbot merge -f "looks good" |
Merge startedYour change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
|
@pytorchbot merge -c nosignal -m "need to back out for merge conflict" |
|
❌ 🤖 pytorchbot command failed: Try |
|
@pytorchbot revert -c nosignal -m "need to back out for merge conflict" |
|
@pytorchbot successfully started a revert job. Check the current status here. |
#136972)" This reverts commit 3ff2d93. Reverted #136972 on behalf of https://github.com/ezyang due to need to back out for merge conflict ([comment](#136972 (comment)))
|
@ezyang your PR has been successfully reverted. |
…ch#136972) Signed-off-by: Edward Z. Yang <ezyang@meta.com> Pull Request resolved: pytorch#136972 Approved by: https://github.com/Skylion007 ghstack dependencies: pytorch#136917, pytorch#136934, pytorch#136935
pytorch#136972)" This reverts commit 3ff2d93. Reverted pytorch#136972 on behalf of https://github.com/ezyang due to need to back out for merge conflict ([comment](pytorch#136972 (comment)))
…ch#136972) Signed-off-by: Edward Z. Yang <ezyang@meta.com> Pull Request resolved: pytorch#136972 Approved by: https://github.com/Skylion007 ghstack dependencies: pytorch#136934, pytorch#136935
…ytorch#137019) Signed-off-by: Edward Z. Yang <ezyang@meta.com> Pull Request resolved: pytorch#137019 Approved by: https://github.com/Skylion007 ghstack dependencies: pytorch#136934, pytorch#136935, pytorch#136972
Stack from ghstack (oldest at bottom):
Signed-off-by: Edward Z. Yang ezyang@meta.com
cc @jgong5 @mingfeima @XiaobingSuper @sanchitintel @ashokei @jingxu10 @voznesenskym @penguinwu @EikanWang @Guobing-Chen @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @ipiszy @yf225 @chenyang78 @kadeng @muchulee8 @ColinPeppler @amjames @desertfire @chauhang @rec