microsoft / onnxruntime

ONNX Runtime: cross-platform, high performance ML inferencing and training accelerator
https://onnxruntime.ai
MIT License
14.7k stars 2.93k forks source link

how to trace the error "assert node is not None" when use the onnxruntime.transformers.optimizer #16268

Open feng-1985 opened 1 year ago

feng-1985 commented 1 year ago

Describe the issue

optimizer the transformer (bert) model, raise this error "assert node is not None"

To reproduce

I am use this script and datasets sequence labeling, and running just five epoch.

After convert the torch model to onnx model, then use the following command to optimizer onnx model. python -m onnxruntime.transformers.optimizer --input xxx.onnx --output xxx_optimizer.onnx

Urgency

No response

Platform

Linux

OS Version

ubuntu 18

ONNX Runtime Installation

Released Package

ONNX Runtime Version or Commit ID

1.6

ONNX Runtime API

Python

Architecture

X64

Execution Provider

CUDA

Execution Provider Library Version

No response

tianleiwu commented 1 year ago

@feng-1985,

ONNX Runtime version 1.6 is very old. Could you try 1.14.1 and 1.15?

feng-1985 commented 1 year ago

cuda is 10.2. so i can't use newer onnxruntime version