Skip to content

ORT throws exception on Session Creation when ORT_ENABLE_ALL is set, but not ORT_ENABLE_LAYOUT (WindowsML) #26717

@rsolorzanomsft

Description

@rsolorzanomsft

Describe the issue

When I try to initialize the ORT session with all optimizations enabled and EP policy OrtExecutionProviderDevicePolicy_PREFER_CPU, I get the following exception:

"C:\__w\1\s\win-onnxruntime\onnxruntime\core\graph\graph_utils.cc:30 onnxruntime::graph_utils::GetIndexFromName itr != node_args.end() was false. Attempting to get index by a name which does not exist:InsertedPrecisionFreeCast_/lstm/layer_norms.0/Constant_output_0 for node: /lstm/layer_norms.0/Mul/SimplifiedLayerNormFusion/

For now, this is just using the CPU EP. I am currently working around this by setting ORT_ENABLE_LAYOUT instead of ORT_ENABLE_ALL.

Another interesting note, the model used if FP16 – this could be causing some issues.

To reproduce

This only reproduces with a private model. I would first try with a FP16 model to see if that's what's causing the issue. If not, then reach out to me and we can see if we can get a repro set up.

Urgency

No response

Platform

Windows

OS Version

24H2

ONNX Runtime Installation

Released Package

ONNX Runtime Version or Commit ID

23

ONNX Runtime API

WinML

Architecture

X64

Execution Provider

CPU

Execution Provider Library Version

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions