[TFLite][Frontend] Fix test failures caused by div-by-zero#15844
Merged
Lunderberg merged 12 commits intoapache:mainfrom Oct 10, 2023
Merged
[TFLite][Frontend] Fix test failures caused by div-by-zero#15844Lunderberg merged 12 commits intoapache:mainfrom
Lunderberg merged 12 commits intoapache:mainfrom
Conversation
Lunderberg
reviewed
Oct 2, 2023
Lunderberg
reviewed
Oct 3, 2023
Contributor
Author
|
@Lunderberg hi! sorry to bug. is this PR still needed? |
Contributor
|
@p3achyjr Thank you for the reminder, and it would still be good to get this PR in, even if re-enabling the flaky |
Lunderberg
approved these changes
Oct 10, 2023
Contributor
Lunderberg
left a comment
There was a problem hiding this comment.
Thank you for making the changes, and LGTM!
Contributor
Author
|
@Lunderberg thanks for getting back!! |
| raise ZeroDivisionError("Input range is 0.") | ||
|
|
||
| # only compute for rhs. | ||
| quant_scale = 255 / (inq1_max - inq1_min) |
Contributor
There was a problem hiding this comment.
Shouldn't there be a dependency on the data type for the value 255? Since the data type can be int8, int16.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Tests were failing b/c TVM and TFLite disagree on div-by-zero cases.
floor_mod still fails, this is probably a behaviorial difference.
#15148