mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-24 19:43:35 +00:00
Fix a bug in SaveInputOutputNamesToNodeMapping function (#18456)
### Description Fix a bug in SaveInputOutputNamesToNodeMapping function. The fix was provided by Scott. ### Motivation and Context
This commit is contained in:
parent
0a4d76d98b
commit
cc840c5289
1 changed files with 1 additions and 2 deletions
|
|
@ -455,11 +455,10 @@ common::Status SaveInputOutputNamesToNodeMapping(const onnxruntime::GraphViewer&
|
|||
// utils::CopyOneInputAcrossDevices is happy.
|
||||
|
||||
auto& input_map = session_state.GetInputNodeInfoMap();
|
||||
auto end_map = input_map.cend();
|
||||
|
||||
for (const auto& graph_input : graph_inputs) {
|
||||
const auto& name = graph_input->Name();
|
||||
if (input_map.find(name) == end_map) {
|
||||
if (input_map.find(name) == input_map.cend()) {
|
||||
// dummy entry for an input that we didn't find a use of in the graph. log it in case that's a bug.
|
||||
// utils::CopyOneInputAcrossDevices will use the input OrtValue as is given we don't believe it's used anywhere.
|
||||
LOGS(session_state.Logger(), INFO) << (graph.IsSubgraph() ? "Subgraph" : "Graph") << " input with name "
|
||||
|
|
|
|||
Loading…
Reference in a new issue