-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Use zeros for NJT dummy to avoid messing with randomness #122902
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
[ghstack-poisoned]
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/122902
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit bc9f2a4 with merge base 1e8d4b3 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
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!
|
@pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
| values=torch.zeros(3, 3, device="meta"), | ||
| offsets=torch.zeros(3, device="meta", dtype=torch.int64), |
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.
Is it possible to add a test case for what vincent was running into?
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.
I tried but wasn't able to repro it after #122704 landed. I decided to make the change here anyway to avoid any other unforeseen randomness-related problems
This broke [internal tests](https://www.internalfb.com/intern/test/844425064039866/) that run with unset `NDEBUG`. It wasn't initially caught because we don't test with unset `NDEBUG` in OSS CI. Pull Request resolved: #122917 Approved by: https://github.com/soulitzer ghstack dependencies: #122902
) Use of randomness was breaking vmap. Pull Request resolved: pytorch#122902 Approved by: https://github.com/vmoens, https://github.com/zou3519
This broke [internal tests](https://www.internalfb.com/intern/test/844425064039866/) that run with unset `NDEBUG`. It wasn't initially caught because we don't test with unset `NDEBUG` in OSS CI. Pull Request resolved: pytorch#122917 Approved by: https://github.com/soulitzer ghstack dependencies: pytorch#122902
Stack from ghstack (oldest at bottom):
Use of randomness was breaking vmap.