Skip to content

Commit

Permalink
Fix mistake in value_info_sorted variable name
Browse files Browse the repository at this point in the history
  • Loading branch information
sspintel committed May 22, 2024
1 parent c748214 commit c59ab04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion onnxruntime/core/graph/graph.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4066,7 +4066,7 @@ void Graph::ToGraphProtoInternal(ONNX_NAMESPACE::GraphProto& graph_proto) const
// to this function, its values are consistently written to the GraphProto
auto sort_predicate = [](const NodeArg* v1, const NodeArg* v2) { return v1->Name() < v2->Name(); };
std::vector<const NodeArg*> value_info_sorted{value_info_.begin(), value_info_.end()};
std::sort(value_info_sorted.begin(), value_info_set.end(), sort_predicate);
std::sort(value_info_sorted.begin(), value_info_sorted.end(), sort_predicate);

for (const auto* value_info : value_info_sorted) {
*(graph_proto.mutable_value_info()->Add()) = value_info->ToProto();
Expand Down

0 comments on commit c59ab04

Please sign in to comment.