-
Notifications
You must be signed in to change notification settings - Fork 671
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
[numeric] Numeric error for Conv operator with quantize/dequantize #19416
Comments
What model is this coming from? The fact that the bias quantization scale is not the same as the product of weight and input scales is concerning. I would not expect us to have comparable numerics for such an example without some additional work in the |
See https://github.com/zjgarvey/SHARK-TestSuite/tree/conv_numerics_repro for operator level tests in the test suite. You can run both of the examples with:
If all of our models are failing because of bias, weight, and input scale mismatches, we should add support for this behavior at the torch-mlir level. |
Hi @pdhirajkumarprasad , I've tried to compile your code but got the following : error: failed to legalize operation 'torch.operator' that was explicitly marked illegal Any Idea on how to make it compile ? |
What was your compile command? |
@zjgarvey As mentioned with problem, I am using following command and able to see the issue I reported
|
@pdhirajkumarprasad , I was asking @JibAxelera , since they had some compilation failure that doesn't make sense to me. This compiles for me fine with your reproducing command on
|
@pdhirajkumarprasad Do you mind if I move this issue to torch-mlir? The reason for the error is the discrepancy between input, weight, and bias quantization scales and we aren't handling this correctly in torch-mlir. |
@zjgarvey Yes, please |
Closing this issue in favor of filing in torch-mlir: llvm/torch-mlir#4059 |
What happened?
For the given IR
getting numeric error as
Steps to reproduce your issue
command:
Version : IREE compiler version 3.1.0rc20241208 @ 39c56de
golden_output.0.bin.txt
input.0.bin.txt
input.1.bin.txt
model.torch_onnx.mlir.txt
model impacted: fbnetv3_d.ra2_in1k* and other, total 50+ models
What component(s) does this issue relate to?
Runtime
Version information
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: