Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[xgboost] Using onnx==1.14.0 & onnxruntime==1.15.1 with target_opset=15 raises NOT_IMPLEMENTED #701

Open
pvardanis opened this issue Oct 2, 2024 · 1 comment

Comments

@pvardanis
Copy link

I've upgraded my library to use onnx==1.14.0 & onnxruntime==1.15.1 with onnxmltools==1.12.0. An exported model that previously worked with onnx==1.12.0 & onnxruntime==1.13.0 now exports successfully but fails to load using an InferenceSession raising the following:

>       sess.initialize_session(providers, provider_options, disabled_optimizers)
E       onnxruntime.capi.onnxruntime_pybind11_state.NotImplemented: [ONNXRuntimeError] : 9 : NOT_IMPLEMENTED : Could not find an implementation for Reshape(19) node with name 'reshape_node'

The model I'm exporting is a simple XGBRegressor:

X, y = diabetes_data
model = XGBRegressor()
model.fit(X, y)

with the same target_opset=15 simply because onnxconverter_common doesn't support higher than this.

Looking at the official onnx docs, onnxruntime==1.15 & onnx==1.14 support up to 19 but this isn't possible. Could that be the cause of the error?
image

@xadupre
Copy link
Collaborator

xadupre commented Oct 3, 2024

Can you check the opset written in the onnx model? (with netron for example)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants