-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[microNPU] Adding rounding mode attribute to operators #9514
Conversation
python/tvm/relay/backend/contrib/ethosu/tir_to_cs_translator.py
Outdated
Show resolved
Hide resolved
Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero. Change-Id: I0942e9d61f6219c757b109a365a95066296691b2
Change-Id: I6ae364c6cc84728376c11288895635acb204d27f
5f8a19c
to
393ac8b
Compare
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.
Looks great to me! Thanks @lhutton1 .
I see that the PR adds functionality to successfully convey the round mode to Vela APIs. However, I assume it would be hard to test it ? In that case, will there be a subsequent PR that uses this feature E2E ?
Thanks @NicolaLancellotti, @manupa-arm for the reviews! Yes, I think it would be quite difficult to test each rounding scheme fully. The implementation of MEAN would rely on all three schemes being used, so this would be a good E2E test. |
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.
LGTM! Thank you @lhutton1
Thanks @lhutton1 @NicolaLancellotti . This is merged now!. |
* [microNPU] Adding rounding mode attribute to operators Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
* [microNPU] Adding rounding mode attribute to operators Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
* [microNPU] Adding rounding mode attribute to operators Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
* [microNPU] Adding rounding mode attribute to operators Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
* [microNPU] Adding rounding mode attribute to operators Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
Allows rounding mode to be specified for each supported operator. By default "TFL" is used, which matches that of the behavior of TFLite. Other rounding mode options include "NATURAL" which rounds to the nearest value and "TRUNCATE" which rounds towards zero.
cc @ekalda @manupa-arm @NicolaLancellotti @dchauhan-arm @mbaret