-
Notifications
You must be signed in to change notification settings - Fork 24.6k
Handle complex optimization in Adamax by treating complex numbers as 2D real numbers #80319
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
✅ No Failures (0 Pending)As of commit 3b93dd5 (more details on the Dr. CI page): Expand to see more💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Please report bugs/suggestions to the (internal) Dr. CI Users group. |
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?
27a1ae7
to
5d4b099
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.
Small not needed, sounds good otherwise.
torch/optim/adamax.py
Outdated
@@ -229,6 +235,11 @@ def _single_tensor_adamax(params: List[Tensor], | |||
|
|||
param.addcdiv_(exp_avg, exp_inf, value=-clr) | |||
|
|||
if torch.is_complex(param): |
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.
Not needed
5d4b099
to
3b93dd5
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.
SGTM
@pytorchbot merge |
@pytorchbot successfully started a merge job. Check the current status here |
Hey @zaxtax. |
…2D real numbers (#80319) (#80319) Summary: This commit partially addresses #65711 Pull Request resolved: #80319 Approved by: https://github.com/albanD Test Plan: contbuild & OSS CI, see https://hud.pytorch.org/commit/pytorch/pytorch/c54d18dbc7bb2f9fdd83c5de529702e5a02295c3 Reviewed By: kit1980 Differential Revision: D38478847 fbshipit-source-id: 1174bc09fb1815d365dff6a44e2f0337501af1af
This commit partially addresses #65711