-
Notifications
You must be signed in to change notification settings - Fork 3.8k
[CMSIS-NN] Support for int16 in fully connected layer #13484
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
Conversation
Support for int16 fully_connected via CMSIS-NN -Pattern matching and RelatToTIR introduce int16 support -Added int16 variants to fully_connected tests
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment. Generated by tvm-bot |
asparkhi
left a comment
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.
Thanks for the changes @neildhickey :) Looks great overall. Just a nit and a request.
| fc_call = requantize_input; | ||
| } | ||
|
|
||
| int32_t dtype_bits = fc_call->args[0]->type_as<TensorTypeNode>()->dtype.bits(); |
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.
nit: a comment maybe?
| } else { | ||
| clip_min = -128; | ||
| clip_max = 127; | ||
| clip_min = -static_cast<int>(1 << dtype_bits); |
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.
Could you please also have a look at
| int32_t clip_min = std::numeric_limits<int8_t>::min(); |
asparkhi
left a comment
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.
Thanks @neildhickey for addressing the comments. Congratulations on the first TVM PR 💯
Support for int16 fully_connected via CMSIS-NN
-Pattern matching and RelayToTIR introduce int16 support
-Added int16 variants to fully_connected tests