Skip to content

Commit 168b17e

Browse files
markknofflerguitargeek
authored andcommitted
[tmva][sofie] Fix ONNX fusion child indexing
nodesChildren is keyed by original graph node indices, while the parse loop iterates over nodesOrder positions. Use nodesOrder[i] to retrieve the correct child list for the currently parsed node and avoid incorrect fusion pairing on reordered graphs.
1 parent 0e45a9e commit 168b17e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tmva/sofie_parsers/src/RModelParser_ONNX.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,7 @@ void RModelParser_ONNX::ParseONNXGraph(RModel & rmodel, const onnx::GraphProto &
873873
std::cout << "\t" << i << " " << nodesOrder[i] << " parsing operator " << op_type << std::endl;
874874
}
875875

876-
std::unique_ptr<ROperator> op = ParseOperator(i, graph, nodesOrder, nodesChildren[i]);
876+
std::unique_ptr<ROperator> op = ParseOperator(i, graph, nodesOrder, nodesChildren[nodesOrder[i]]);
877877
if (!op) {
878878
if (verbose) {
879879
std::cout << "\t\tskipping operator since it is fused with previous one" << std::endl;

0 commit comments

Comments
 (0)