From f170f31e1dbade5ee71d519a006051a6fae7612d Mon Sep 17 00:00:00 2001 From: Jeff Bloomfield <38966965+jeffbloo@users.noreply.github.com> Date: Tue, 12 May 2020 14:04:09 -0700 Subject: [PATCH] Extend workaround with input name matching in DML fused graph kernel (#3918) --- .../dml/DmlExecutionProvider/src/GraphDescBuilder.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/onnxruntime/core/providers/dml/DmlExecutionProvider/src/GraphDescBuilder.cpp b/onnxruntime/core/providers/dml/DmlExecutionProvider/src/GraphDescBuilder.cpp index d806303fa0..0dc908f5aa 100644 --- a/onnxruntime/core/providers/dml/DmlExecutionProvider/src/GraphDescBuilder.cpp +++ b/onnxruntime/core/providers/dml/DmlExecutionProvider/src/GraphDescBuilder.cpp @@ -205,6 +205,14 @@ namespace Dml::GraphDescBuilder if (arg->Exists()) { auto iter = nameToFusedNodeInputIndex.find(arg->Name()); + + // The graph input could be missing the suffix, so try to match without it. + // This is part of a temporary workaround; see comments in GetFusedNodeArgNameMatchingGraph. + if (iter == nameToFusedNodeInputIndex.end()) + { + iter = nameToFusedNodeInputIndex.find(GetFusedNodeArgNameMatchingGraph(arg->Name())); + } + if (iter != nameToFusedNodeInputIndex.end()) { // This is a graph input