Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion onnxruntime/contrib_ops/cpu/utils/debug_macros.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#ifdef DEBUG_GENERATION
#define DUMP_TENSOR_LEVEL 2
#else
#define DUMP_TENSOR_LEVEL 0 // change it to 1 or 2 if want to enable dumping for code not in generation.
#define DUMP_TENSOR_LEVEL 1 // change it to 1 or 2 if want to enable dumping for code not in generation.
#endif

#define DUMP_CPU_TENSOR_LEVEL DUMP_TENSOR_LEVEL
Expand Down
5 changes: 3 additions & 2 deletions onnxruntime/core/providers/openvino/backends/basic_backend.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ struct OnnxToOvNetworkBindings {
"beam_idx",
"past_key_values",
"present",
"total_seq_len",
};

OnnxToOvNetworkBindings(OVExeNetwork& exec_network, SubGraphContext& subgraph_context, SessionContext& session_context) {
Expand All @@ -72,15 +73,15 @@ struct OnnxToOvNetworkBindings {
// stateful representation has introduced these new tensors, creating a name mismatch (matched_names=false).
// So, if there is a name mismatch, or the name matches our special io list, we simply continue processing
// here to prevent runtime exceptions.
if (session_context.enable_causallm) {
//if (session_context.enable_causallm) {
if (!matched_names ||
std::any_of(special_io_names_.begin(), special_io_names_.end(),
[&onnx_name](const std::string& name) { return onnx_name.find(name) != std::string::npos; })) {
// This case also requires dynamic shape inference, so we'll mark the bindings as dynamic.
has_dynamic_io_ = true;
continue;
}
}
//}

ORT_ENFORCE(matched_names, log_tag,
"Input names mismatch between OpenVINO and ONNX. ", onnx_name,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ std::vector<SupportedOp> supported_op_mode = {
{"Atanh", V_2020_4, {"CPU"}},
{"Atanh", V_2022_1, {"GPU"}},
{"Attention", V_2023_0, {"CPU", "GPU"}},
{"GroupQueryAttention", V_2023_0, {"CPU", "GPU"}},
{"AveragePool", V_2020_4, {"CPU", "GPU"}},
{"BatchNormalization", V_2020_4, {"CPU", "GPU"}},
{"BiasGelu", V_2023_0, {"CPU", "GPU"}},
Expand Down
3 changes: 3 additions & 0 deletions tools/ci_build/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,9 @@ def generate_build_tree(
"-Donnxruntime_ENABLE_PIX_FOR_WEBGPU_EP=" + ("ON" if args.enable_pix_capture else "OFF"),
]

if 1: #args.dump_node_input_output:
cmake_args.append("-Donnxruntime_DEBUG_NODE_INPUTS_OUTPUTS=ON")

if args.caller_framework:
cmake_args.append("-Donnxruntime_CALLER_FRAMEWORK=" + args.caller_framework)
if args.winml_root_namespace_override:
Expand Down
6 changes: 6 additions & 0 deletions tools/ci_build/build_args.py
Original file line number Diff line number Diff line change
Expand Up @@ -842,6 +842,12 @@ def convert_arg_line_to_args(self, arg_line: str) -> list[str]: # Use list[str]
fromfile_prefix_chars="@", # Allow args from file (@filename)
)

# dump_node_input_output
parser.add_argument(
"--dump_node_input_output",
type=str,
help="Dump node input/output data to files in the specified directory.",
)
# Add arguments by category
add_core_build_args(parser)
add_cmake_build_config_args(parser)
Expand Down
Loading