Functionalization in PyTorch

Functionalization in PyTorch: Everything You Wanted To Know – compiler – PyTorch Developer Mailing List

Over a year old, but a very in depth breakdown from Brian Hirsh of how AOTAutograd functionlizes – e.g. removes mutations from – various graphs, what that enables, and what kind of edge cases exist. Inductor as a backend can handle mutation, but many other situations (including export!) can’t. It got bumped up because of a question on exactly that!

torch.export uses functionalization. In particular, when you export for inference, you’ll get out a functionalized ATen graph!

Get new posts by email

If you enjoyed this, subscribe and the next post will land in your inbox. No spam, unsubscribe any time.

Prefer a feed reader? Follow along via RSS.