-
Notifications
You must be signed in to change notification settings - Fork 22.9k
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 prelu_backward TensorIterator split #36134
Conversation
Also add a `TORCH_INTERNAL_ASSERT_DEBUG_ONLY` to test for this.
💊 Build failures summary and remediationsAs of commit dcdbc28 (more details on the Dr. CI page): ✅ None of the build failures appear to be your fault 💚
❄️ 1 tentatively flaky failure1 failure tentatively classified as flaky but reruns have not yet been triggered to confirm: pytorch_linux_xenial_cuda10_2_cudnn7_py3_gcc7_test (1/1)Step: "Set Up CI Environment After attach_workspace" (full log | pattern match details | 🔁 rerun) ❄️
|
Wait, please hold on for now, seems the testing for prelu backward is missing some cases, I will add them later in this PR. |
@zasdfgbnm If you rebase on top of pytorch/master the XLA failure should be gone as well. Thanks! |
OffsetCalculator<2>(iter.ndim(), iter.shape().data(), out_strides.data()) | ||
); | ||
} | ||
TORCH_INTERNAL_ASSERT(iter.is_contiguous()); |
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.
Caller of launch_prelu_cuda_backward_share_weights_kernel
already guarantees contiguous.
@VitalyFedyunin This PR is now ready. This is a bug fix for my previous prelu |
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.
@VitalyFedyunin has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
@VitalyFedyunin merged this pull request in 438aed6. |
We should have
But I mistakenly wrote it as
in my previous PR. Which leads to infinite recursion on it.
I found this bug when working on #34004
I also add a
TORCH_INTERNAL_ASSERT_DEBUG_ONLY
to test for this.Besides, the caller is already guaranteed contiguous, so we don't need to handle no-contiguous tensors.