-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Add missing in-place on view check to custom autograd.Function #153094
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/153094
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New Failure, 3 Unrelated FailuresAs of commit d5c8945 with merge base e2c7ae5 ( NEW FAILURE - The following job has failed:
FLAKY - The following job failed but was likely due to flakiness present on trunk:
UNSTABLE - The following jobs are marked as unstable, possibly due to flakiness on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
…tion" Fixes #152773 [ghstack-poisoned]
if (cdata) { | ||
impl::rebase_history(var, {cdata, output_nr}); | ||
} | ||
check_inplace(var, true); |
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.
You assume this will never raise right? Because we do more restrictive checks above?
If so, let's leave a small comment about it.
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.
Indeed it will never raise for some of its checks like leaf mutation.
However, it will raise in cases like checking whether the view is default (which is why we add it here :P)
…tion" Fixes #152773 [ghstack-poisoned]
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 this BC-breaking then?
…tion" Fixes #152773 [ghstack-poisoned]
Yes, specifically in the case of in-place on view of leaf case where we previously leaked, but now properly raise an error! (Just added a test for this) In summary:
|
@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 |
Merge failedReason: 1 mandatory check(s) failed. The first few are: Dig deeper by viewing the failures on hud |
@pytorchbot merge -i |
Merge startedYour change will be merged while ignoring the following 4 checks: pull / linux-focal-py3_9-clang9-xla / build, pull / unstable-linux-focal-cuda12.6-py3.10-gcc11-sm89-xfail / build, pull / linux-jammy-py3-clang12-executorch / test (executorch, 1, 1, ephemeral.linux.2xlarge), trunk / macos-py3-arm64 / test (default, 1, 3, macos-m1-stable) Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Stack from ghstack (oldest at bottom):
Fixes #152773
cc @ezyang @gchanan