diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 49676926..550eda77 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -7,6 +7,14 @@ Change log ========== +0.9.3 (Unreleased) +------------------ + +**Bug fix** + +- Address missing Value Infos when building singleton model for shape inference. + + 0.9.2 (2023-10-18) ------------------ @@ -14,10 +22,17 @@ Change log - Fix a deprecation warning from one of Spox's dependencies. +0.9.2 (2023-10-20) +------------------ + +**Other changes** + +- Fix a deprecation warning from one of Spox's dependencies. + 0.9.1 (2023-10-05) ------------------ -**Bug fix** +**Bug fixes** - The node-adaption no longer fails if faced with a node that has repeating inputs. - Forego version adaption of inlined models if no nodes are from the default domain. diff --git a/src/spox/_standard.py b/src/spox/_standard.py index aca55a41..c7772310 100644 --- a/src/spox/_standard.py +++ b/src/spox/_standard.py @@ -244,12 +244,16 @@ def _make_dummy_subgraph(_node: Node, key: str, graph: "Graph") -> onnx.GraphPro inputs = [] for i, arr in enumerate(graph.requested_arguments): inputs.append(arr.unwrap_type()._to_onnx_value_info(f"__dummy_input{i}")) + + value_infos = [] nodes = [] outputs = [] for i, arr in enumerate(graph.requested_results.values()): outer = f"__dummy_outer_output{i}" + value_infos.append(arr.unwrap_type()._to_onnx_value_info(outer)) out = f"__dummy_output{i}" outputs.append(arr.unwrap_type()._to_onnx_value_info(out)) nodes.append(onnx.helper.make_node("Identity", [outer], [out])) - - return onnx.helper.make_graph(nodes, f"__dummy_{key}", inputs, outputs) + return onnx.helper.make_graph( + nodes, f"__dummy_{key}", inputs, outputs, value_info=value_infos + ) diff --git a/tests/test_adapt.py b/tests/test_adapt.py index a91f8c06..3511963f 100644 --- a/tests/test_adapt.py +++ b/tests/test_adapt.py @@ -26,7 +26,7 @@ def old_squeeze() -> onnx.ModelProto: > agraph (float[1, N] A) => (float[N] B) { - B = Squeeze(A) + B = Squeeze(A) } """ )