-
Notifications
You must be signed in to change notification settings - Fork 26.3k
Fix linspace step computation for large integral types #40132
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
Fix linspace step computation for large integral types #40132
Conversation
pbelevich
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.
Is it worth it to add a test for this case?
xuhdev
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.
Could you also add a comment?
3ddaa91 to
30a7ac4
Compare
💊 CI failures summary and remediationsAs of commit 9014baf (more details on the Dr. CI page): 💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.Please report bugs/suggestions on the GitHub issue tracker or post in the (internal) Dr. CI Users group. This comment has been revised 6 times. |
30a7ac4 to
a2db92f
Compare
facebook-github-bot
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.
@malfet is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
Convert start and end to `step_t` before computing the difference Should fix `torch.linspace(-2147483647, 2147483647, 10, dtype=torch.int32)`
a2db92f to
9014baf
Compare
facebook-github-bot
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.
@malfet is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
Convert start and end to
step_tbefore computing the differenceShould fix
torch.linspace(-2147483647, 2147483647, 10, dtype=torch.int32)Closes #40118