pytorch/torch/_dynamo/variables
Michael Voznesensky bc19494814 [Dynamo] Symbolic shape guards (#87570)
**Introduces symbolic shape guards into dynamo.**

In this PR, we take the existing fake tensor infra and plumbing in dynamo and we start passing a shape_env around. This shape_env does not get plumbed down to middle layers / backend yet - it only collects expressions from frontend invocations at the moment. We then translate these expressions into guards at the point where we take other guards installed throughout dynamo - and add them to check_fn.

Part 1 of https://docs.google.com/document/d/1QJ-M4zfMkD-fjHIqW089RptjLl9EgozZGCceUbvmgfY/edit#

cc @jansel @lezcano @fdrocha @mlazos @soumith @yanboliang @penguinwu @anijain2305
Pull Request resolved: https://github.com/pytorch/pytorch/pull/87570
Approved by: https://github.com/ezyang
2022-10-25 21:15:40 +00:00
..
__init__.py
base.py
builder.py [Dynamo] Support optimizing over any Tensor with requires_grad = True (#87141) 2022-10-19 22:13:07 +00:00
builtin.py [Dynamo] Symbolic shape guards (#87570) 2022-10-25 21:15:40 +00:00
constant.py
dicts.py [Dynamo] Support optimizing over any Tensor with requires_grad = True (#87141) 2022-10-19 22:13:07 +00:00
functions.py [dynamo] Introduce get_real_value API to TensorVariable (#87091) 2022-10-17 20:14:43 +00:00
lists.py Fix stupid N^2 naming behavior in FX and removed assert that slows things a lot sometimes (#87533) 2022-10-23 08:26:37 +00:00
misc.py Revert "Dynamo FX graph stack traceback fix (#87136)" 2022-10-19 18:57:24 +00:00
nn_module.py Add named_buffers to torchdynamo nn_module (#87644) 2022-10-25 17:00:56 +00:00
tensor.py [Dynamo] Symbolic shape guards (#87570) 2022-10-25 21:15:40 +00:00
torch.py [Dynamo] Symbolic shape guards (#87570) 2022-10-25 21:15:40 +00:00
user_defined.py