Skip to content

Commit 7781609

Browse files
committed
fix doc
1 parent aa5b0b5 commit 7781609

File tree

2 files changed

+7
-10
lines changed

2 files changed

+7
-10
lines changed

_doc/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@
126126
("py:class", "transformers.configuration_utils.PretrainedConfig"),
127127
("py:func", "torch.export._draft_export.draft_export"),
128128
("py:func", "torch._export.tools.report_exportability"),
129+
("py:func", "torch.utils._pytree.register_pytree_node"),
129130
("py:meth", "huggingface_hub.HfApi.list_models"),
130131
("py:meth", "transformers.AutoConfig.from_pretrained"),
131132
("py:meth", "transformers.GenerationMixin.generate"),

_doc/examples/plot_export_with_args_kwargs.py

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,16 @@
11
"""
22
.. _l-plot-export-with-args-kwargs:
33
4-
==================================
5-
Dynamic Shapes for *args, **kwargs
6-
==================================
4+
==========================================
5+
Dynamic Shapes for ``*args``, ``**kwargs``
6+
==========================================
77
88
Quick tour of dynamic shapes.
9-
10-
Simple Examples
11-
===============
12-
139
We first look at examples playing positional and names parameters
1410
to understand how :func:`torch.export.export` works.
1511
1612
args
17-
++++
13+
====
1814
"""
1915

2016
import pprint
@@ -59,7 +55,7 @@ def forward(self, x, y):
5955

6056
# %%
6157
# kwargs
62-
# ++++++
58+
# ======
6359
#
6460
# We do the same with named arguments.
6561

@@ -88,7 +84,7 @@ def forward(self, x, y):
8884

8985
# %%
9086
# args and kwargs
91-
# +++++++++++++++
87+
# ===============
9288
#
9389
# :func:`torch.export.export` does not like having dynami shapes
9490
# for both args and kwargs. We need to define them using one mechanism.

0 commit comments

Comments
 (0)