[DTensor] Skip all-zero ground truth samples in strategy validator#174535
Closed
wconstab wants to merge 5 commits intogh/wconstab/522/basefrom
Closed
[DTensor] Skip all-zero ground truth samples in strategy validator#174535wconstab wants to merge 5 commits intogh/wconstab/522/basefrom
wconstab wants to merge 5 commits intogh/wconstab/522/basefrom
Conversation
Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. [ghstack-poisoned]
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/174535
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 37 PendingAs of commit 894f5c5 with merge base f365425 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This was referenced Feb 8, 2026
…alidator" Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. [ghstack-poisoned]
pianpwk
approved these changes
Feb 9, 2026
Contributor
pianpwk
left a comment
There was a problem hiding this comment.
Another common case is all True/False values for boolean tensors.
To be extremely conservative, I'd also consider filtering out cases with all-zeros input tensors, since that can be error prone. Something like scatter_add(input: R, index: S, values: S) -> P could be a false positive, when the input tensor is all zeros
…alidator" Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. [ghstack-poisoned]
…alidator" Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. [ghstack-poisoned]
…alidator" Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. [ghstack-poisoned]
Contributor
Author
|
squashed |
sandy-gags
pushed a commit
to sandy-gags/pytorch
that referenced
this pull request
Mar 12, 2026
Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. ghstack-source-id: 5d7d67d Pull Request resolved: pytorch/pytorch#174535
sandy-gags
pushed a commit
to sandy-gags/pytorch
that referenced
this pull request
Mar 12, 2026
Moves the all-zero detection from validate_combination to compare_operator. validate_combination correctly reports that the computation produces matching results for zero inputs, but the sample is uninformative for distinguishing valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always produce zero output, and without this skip every placement combination trivially validates, generating hundreds of false positive rules. Authored with Claude. ghstack-source-id: b52c26b Pull Request resolved: pytorch/pytorch#174535
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack from ghstack (oldest at bottom):
Moves the all-zero detection from validate_combination to compare_operator.
validate_combination correctly reports that the computation produces matching
results for zero inputs, but the sample is uninformative for distinguishing
valid from invalid rules. Ops like zeros_like, zero_, and new_zeros always
produce zero output, and without this skip every placement combination
trivially validates, generating hundreds of false positive rules.
Authored with Claude.