You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary:
Pull Request resolved: #296
In light of two stage APIs, export documentation neeeds to change.
Update also links to the gh issue, establishing context and the need for the
change, along with highlighting what is the long term plan for export API.
Reviewed By: mergennachin
Differential Revision: D49209531
fbshipit-source-id: 6c9dd56609f663f57090ecbba5bb8e2b5de94411
Copy file name to clipboardExpand all lines: docs/website/docs/tutorials/exporting_to_executorch.md
+25-16Lines changed: 25 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -32,9 +32,10 @@ embedded devices. At a high level, the AOT steps are the following:
32
32
33
33
### 1.1 Exporting to EXIR ATen Dialect
34
34
35
-
The entrypoint to Executorch is through the `exir.capture` API. This function
36
-
utilizes [torch.export](https://pytorch.org/docs/main/export.html) to
37
-
fully capture a PyTorch Model (either `torch.nn.Module` or a callable) into a
35
+
NB: Export APIs are undergoing changes to align better with long term state of export. Please refer to https://github.com/pytorch/executorch/issues/290, for more details.
36
+
37
+
The entrypoint to Executorch is through the `torch._export.capture_pre_autograd_graph` API, which is used
38
+
to fully capture a PyTorch Model (either `torch.nn.Module` or a callable) into a
38
39
`torch.fx` graph representation.
39
40
40
41
In order for the model to
@@ -48,23 +49,26 @@ through registering the custom operator to a torch library and providing a meta
48
49
kernel. To learn more about exporting a model or if you have trouble exporting,
49
50
you can look at [these docs](../export/00_export_manual.md)
50
51
51
-
To enable exporting input shape-dependent models, the `exir.capture` API also
52
+
To enable exporting input shape-dependent models, this API also
52
53
takes in a list of constraints, where users can specify which input shapes are
53
54
dynamic and impose ranges on them. To learn more about constraints, you can look
54
55
at [these docs](../export/constraint_apis.md)
55
56
56
-
The output of `exir.capture` is a fully flattened graph (meaning the graph does
57
-
not contain any module heirachy, except in the case of control flow operators)
0 commit comments