-
Notifications
You must be signed in to change notification settings - Fork 749
Add complex dtype support to mul #10560
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
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/10560
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit 58b70c0 with merge base 36e44ea ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
This pull request was exported from Phabricator. Differential Revision: D73877440 |
kernels/test/op_mul_test.cpp
Outdated
| // Disabling this for portable mode for now because currently we only support | ||
| // complex dtypes in optimized mode. Portable mode needs support in elementwise_ops.h | ||
| // for complex dtypes, which we don't have yet. | ||
| //ET_FORALL_COMPLEXH_TYPES(TEST_ENTRY); |
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.
The fact that you are commenting out this line means none of the changes you added in this PR are being tested. I agree you shouldn't be blocked by adding support in the elementwise macros. You have two possible solutions:
a) Add your optimized-only tests under https://github.com/pytorch/executorch/tree/main/kernels/optimized/test
b) Enable complex in portable op_mul without messing around with the elementise macros, just add an if/else and add similar code to the one you added in the optimized op.
I think b) will be way easier
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.
@manuelcandales took approach b) and updated the PR.
manuelcandales
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.
Test your code changes either by doing a) or b)
Summary: Adding support for complex dtypes in op_mul. In this diff i'm only adding support in the optimized path and not in the core portable kernels as that needs support in a bunch of the element-wise macro's that i'm not really familiar with. For now this unblocks our internal use cases. Differential Revision: D73877440
545e500 to
58b70c0
Compare
|
This pull request was exported from Phabricator. Differential Revision: D73877440 |
Summary: Adding support for complex dtypes in op_mul. In this diff i'm only adding support in the optimized path and not in the core portable kernels as that needs support in a bunch of the element-wise macro's that i'm not really familiar with. For now this unblocks our internal use cases.
Differential Revision: D73877440