diff --git a/onnxruntime/core/graph/graph.cc b/onnxruntime/core/graph/graph.cc index c633895996dda..fd36241c995bf 100644 --- a/onnxruntime/core/graph/graph.cc +++ b/onnxruntime/core/graph/graph.cc @@ -1310,7 +1310,8 @@ Graph::Graph(const Model& owning_model, } for (const auto& node_proto : graph_proto_->node()) { - AddNode(node_proto, name_to_type_map); + auto& new_node = AddNode(node_proto, name_to_type_map); + SetOpSchemaFromRegistryForNode(new_node); } if (is_loaded_from_model_file_) {