fix pipeline __setattr__ value == None#3063
Merged
patrickvonplaten merged 2 commits intohuggingface:mainfrom Apr 12, 2023
Merged
fix pipeline __setattr__ value == None#3063patrickvonplaten merged 2 commits intohuggingface:mainfrom
patrickvonplaten merged 2 commits intohuggingface:mainfrom
Conversation
williamberman
commented
Apr 12, 2023
Comment on lines
510
to
515
| if hasattr(self, name) and hasattr(self.config, name): | ||
| # We need to overwrite the config if name exists in config | ||
| if isinstance(getattr(self.config, name), (tuple, list)): | ||
| if self.config[name][0] is not None: | ||
| if value is not None and self.config[name][0] is not None: | ||
| class_library_tuple = (value.__module__.split(".")[0], value.__class__.__name__) | ||
| else: |
Contributor
Author
There was a problem hiding this comment.
the setting value can be None with a defined class library tuple on the config -- i.e. if the text encoder is an optional component
I think overwriting the config class library tuple to None in this case is not ideal but acceptable as it isn't common behavior
|
The documentation is not available anymore as the PR was closed or merged. |
w4ffl35
pushed a commit
to w4ffl35/diffusers
that referenced
this pull request
Apr 14, 2023
* fix pipeline __setattr__ * add test --------- Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
dg845
pushed a commit
to dg845/diffusers
that referenced
this pull request
May 6, 2023
* fix pipeline __setattr__ * add test --------- Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
yoonseokjin
pushed a commit
to yoonseokjin/diffusers
that referenced
this pull request
Dec 25, 2023
* fix pipeline __setattr__ * add test --------- Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
AmericanPresidentJimmyCarter
pushed a commit
to AmericanPresidentJimmyCarter/diffusers
that referenced
this pull request
Apr 26, 2024
* fix pipeline __setattr__ * add test --------- Co-authored-by: Patrick von Platen <patrick.v.platen@gmail.com>
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.
No description provided.