Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Fix dequantizelinaer simple case with no zero point present #3526
Fix dequantizelinaer simple case with no zero point present #3526
Changes from all commits
327eeeb
0629540
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this moved down here? We should still check that the inputs are the same dims even when 2 inputs are given. It makes sense up at the top.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That wont be the case though in this operator would it? I guess we broadcast out scale if its a scalar or its 1-d for the case of scale being a tensor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's where the issue was coming from when invoking dequantize_linear, zero points weren't present and resulted in an error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What was the error specifically? This allows either 2 or 3 inputs so it shouldn't throw an error for 2 inputs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would invoke
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless you want us to always broadcast the scale dimensions (even if its 1-d) but then that means we're inserting a broadcast to remove later. For the scale here, we're never supposed to have the same dimensions between input and scale vectors. Its why I gated this check by input size.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually it looks like the op is intended to work this way where the scales and zero points should already be broadcasted. The parser for dequantizelinear also puts this broadcast in. I dont think this is a bug, your test case should have a broadcast for the scales.
Im not sure what you mean by remove later?