Open danyi211 opened 6 months ago
Updating the onnxmltools & onnxconverter-common to the HEAD on github fixes the warning in the first issue.
This issue has been automatically marked as stale due to inactivity and will be closed in 30 days if no further activity occurs. If further support is needed, please provide an update and/or more details.
same warning
I believe the issue is on the tools not being released in a long time.
As mentioned above, installing from HEAD fixed it for me:
pip install git+https://github.com/onnx/onnxmltools git+https://github.com/microsoft/onnxconverter-common
Hi, I think Issue 2 is not solved yet... can anyone help look into this? Thanks
Describe the issue
Issue 1: Converted an xgboost
binary:logistic
model into ONNX, and inference with ONNXRuntime session gives a warning message:The xgboost model prediction is a single value of the probability of class1, while the ONNXRuntime prediction gives a vector of two probabilities [
score_class_0
,score_class_1
], where thescore_class_1
value matches with the xgboost model prediction on the same input vector. The shape of ONNX obviously doesn't match with the xgboost model, so the warning comes up.Is there a way to suppress this warning, or improve the onnx output for xgboost binary classification?
Issue 2: Converted an xgboost
multi:softmax
model (multiclass classification with num_class=2) into ONNX, and inference with ONNXRuntime session.The xgboost model prediction is a vector of two probabilities [
score_class_0
,score_class_1
]. The ONNXRuntime prediction also gives a vector of two probabilities, but the values are inconsistent with the xgboost model on the same input vector.With the same test procedure, I got the following output:
To reproduce
Urgency
No response
Platform
Mac
OS Version
14.1.1
ONNX Runtime Installation
Released Package
ONNX Runtime Version or Commit ID
1.18.0
ONNX Runtime API
Python
Architecture
ARM64
Execution Provider
Default CPU
Execution Provider Library Version
No response