Clean up usage of InputTransform.unique_name_suffix#252
Open
copybara-service[bot] wants to merge 1 commit intomainfrom
Open
Clean up usage of InputTransform.unique_name_suffix#252copybara-service[bot] wants to merge 1 commit intomainfrom
InputTransform.unique_name_suffix#252copybara-service[bot] wants to merge 1 commit intomainfrom
Conversation
617a642 to
18c2a8c
Compare
* Don't ever add `which` automatically, since `self._which` is added by `WrappedStatistic` when it determines `unique_name` * Add missing args to some transforms to ensure uniqueness * Add `unique_name_suffix` to `ShiftAlongNewDim`, since it may take a `Dataset` arg, and we don't want to just insert this. PiperOrigin-RevId: 743185413
18c2a8c to
3a05231
Compare
transform.which in transform.unique_name_suffix. This check ideally would be done in the base class, InputTransform.__init__, but cannot because unique_name_suffix is not determined until *after* base class init.InputTransform.unique_name_suffix
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.
Clean up usage of
InputTransform.unique_name_suffixwhichautomatically, sinceself._whichis added byWrappedStatisticwhen it determinesunique_nameunique_name_suffixtoShiftAlongNewDim, since it may take aDatasetarg, and we don't want to just insert this.