Skip to content

Commit 64cdc47

Browse files
committed
fix doc
1 parent 31304b1 commit 64cdc47

File tree

4 files changed

+12
-4
lines changed

4 files changed

+12
-4
lines changed

_doc/tutorial/onnx_api.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,11 @@ the true implementation would be the following.
7171
n2 = oh.make_node("Pow", ["dxy", "two"], ["dxy2"])
7272
n3 = oh.make_node("ReduceSum", ["dxy2"], [output_name])
7373
graph = oh.make_graph([n1, n2, n3], "euclidian", [X, Y], [Z], [two])
74-
model = oh.make_model(graph, opset_imports=[oh.make_opsetid("", opset)])
74+
model = oh.make_model(
75+
graph,
76+
opset_imports=[oh.make_opsetid("", opset)],
77+
ir_version=9,
78+
)
7579
return model
7680

7781

onnx_array_api/plotting/graphviz_helper.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,7 @@ def plot_dot(
203203
204204
import matplotlib.pyplot as plt
205205
import onnx.parser
206+
from onnx_array_api.plotting.graphviz_helper import plot_dot
206207
207208
model = onnx.parser.parse_model(
208209
'''
@@ -212,7 +213,8 @@ def plot_dot(
212213
four = Add(two, two)
213214
z = Mul(four, four)
214215
}''')
215-
ax = plot_dot(dot)
216+
217+
ax = plot_dot(model)
216218
ax.set_title("Dummy graph")
217219
plt.show()
218220
"""

onnx_array_api/reference/evaluator_yield.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ def enumerate_summarized(
240240
:param feed_inputs: dictionary `{ input name: input value }`
241241
:param raise_exc: raises an exception if the execution fails or stop
242242
where it is
243-
:param keep_tensor:keep the tensor in order to compute precise distances
243+
:param keep_tensor: keep the tensor in order to compute precise distances
244244
:return: iterator on ResultExecution
245245
"""
246246
for kind, name, value, op_type in self.enumerate_results(

onnx_array_api/validation/docs.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ def make_euclidean(
3030
n2 = oh.make_node("Pow", ["dxy", "two"], ["dxy2"])
3131
n3 = oh.make_node("ReduceSum", ["dxy2"], [output_name])
3232
graph = oh.make_graph([n1, n2, n3], "euclidian", [X, Y], [Z], [two])
33-
model = oh.make_model(graph, opset_imports=[oh.make_opsetid("", opset)])
33+
model = oh.make_model(
34+
graph, opset_imports=[oh.make_opsetid("", opset)], ir_version=9
35+
)
3436
return model
3537

3638

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy