You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#Describe the bug
Quantization scales are defined to always be positive in the onnx documentation.
Creating a qdq-enabled onnx-representation using the builder.py lead to plenty of negative scales, contrary to what is stated in the documentation.
It also causes exceptions in various execution providers.
Steps to reproduce the behavior:
Download a model from hugginface, in our case Phi-3.5-mini-instruct.
Create a quantized onnx-represenation from it, with a call similar to this:
When quantizing to INT4 precision, the model builder assumes that the scales are symmetric. When is_symmetric = True, the scales can be positive or negative. If is_symmetric = False, the scales will be non-negative.
#Describe the bug
Quantization scales are defined to always be positive in the onnx documentation.
Creating a qdq-enabled onnx-representation using the
builder.py
lead to plenty of negative scales, contrary to what is stated in the documentation.It also causes exceptions in various execution providers.
Steps to reproduce the behavior:
Phi-3.5-mini-instruct
.netron
DequantizeLinear
node.Inputs
, and therex_scale
. Click on the associated+
-sign on the right.Expected behavior
In Step 6, only 0 or positive values should be visible.
Desktop (please complete the following information):
ubuntu
Screenshots
The text was updated successfully, but these errors were encountered: