-
Notifications
You must be signed in to change notification settings - Fork 355
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
Added Fusion G3 NN library with kernels related to add, mul, quantize… #6738
base: main
Are you sure you want to change the base?
Conversation
…, dequantize, cat, layer norm, softmax to backends/cadence folder. Added operators to backends/cadence folder
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/6738
Note: Links to docs will display an error until the docs builds have been completed. This comment was automatically generated by Dr. CI and updates every 15 minutes. |
Hi @ckmadhira! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
Fusion G3 NN library is added with kernels related to add, mul, quantize, dequantize, cat, layernorm and softmax. Operators which use these kernels are also added to backends/cadence folder |
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 change! Had one comment on the op namespace
|
||
namespace impl { | ||
namespace FusionG3 { | ||
namespace native { |
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.
Can the name spaces of all the G3 ops build as
namespace cadence {
namespace impl {
namespace G3 {
namespace native {
To align with other ops? HiFi example: https://github.com/pytorch/executorch/blob/main/backends/cadence/hifi/operators/op_add.cpp#L25
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.
Updated as per review comment
- op: _softmax.out | ||
kernels: | ||
- arg_meta: null | ||
kernel_name: impl::FusionG3::softmax_out |
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.
Same comment on the namespace
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.
Per @hsharma35 's comment above, please use cadence::impl::G3::native::<OP_NAME> namespace
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.
Updated the operator name as cadence::impl::G3::<OP_NAME>. native is not explicitly mentioned. As per kernel-library-custom-aten-kernel.md, native is automatically appended to the operators.
@@ -0,0 +1,119 @@ | |||
# Copyright (c) Meta Platforms, Inc. and affiliates. |
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.
Please change the kernel_name here to match cadence::impl::G3::native::OP_NAME
. For example: cadence::impl::G3::native::add_out
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.
Updated the operator name as cadence::impl::G3::add_out. native is not explicitly mentioned.
Nit: Can we rename the folder FuG3 to FusionG3 instead? |
@zonglinpeng has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Signed-off-by: cmadhira@cadence.com <mckala@invecas.com>
…, dequantize, cat, layer norm, softmax to backends/cadence folder. Added operators to backends/cadence folder
Summary
[PLEASE REMOVE] See CONTRIBUTING.md's Pull Requests for ExecuTorch PR guidelines.
[PLEASE REMOVE] If this PR closes an issue, please add a
Fixes #<issue-id>
line.[PLEASE REMOVE] If this PR introduces a fix or feature that should be the upcoming release notes, please add a "Release notes: " label. For a list of available release notes labels, check out CONTRIBUTING.md's Pull Requests.
Test plan
[PLEASE REMOVE] How did you test this PR? Please write down any manual commands you used and note down tests that you have written if applicable.