Skip to content

onnxruntime optimizers fails #22512

Description

Describe the issue

The attached model succeeds when onnxruntime optimization are disabled, and fails when all of them are.

  File "onnxruntime/capi/onnxruntime_inference_collection.py", line 491, in _create_inference_session
    sess.initialize_session(providers, provider_options, disabled_optimizers)
onnxruntime.capi.onnxruntime_pybind11_state.Fail: [ONNXRuntimeError] : 1 : FAIL : Node (MatMulBnFusion_Gemm) Op (Gemm) [ShapeInferenceError] First input does not have rank 2

model_levit_128-onnx_dynamo-ir-d0rt0.zip

To reproduce

import onnxruntime
onnxruntime.InferenceSession("<model.onnx>", providers=["CUDAExecutionProvider", "CPUExecutionProvider"])

Urgency

No response

Platform

Linux

OS Version

ubuntu-22.04

ONNX Runtime Installation

Built from Source

ONNX Runtime Version or Commit ID

7880342

ONNX Runtime API

Python

Architecture

X64

Execution Provider

CUDA

Execution Provider Library Version

CUDA 11.8

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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