lllyasviel / lllyasviel/LayerDiffuse_DiffusersCLI
There are bug in diffusers with sdxl
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 425
- Forks
- 40
- PR merge metrics
- No merged PRs in 30d
Description
software version :
diffusers == 0. 29.2
## Bug1:
> AttributeError: 'CLIPTextModelOutput' object has no attribute 'pooler_output'
Because text_encoder is CLIPTextModel , it output is [transformers.modeling_outputs.BaseModelOutputWithPooling](https://huggingface.co/docs/transformers/v4.42.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPooling), so the output contain **pooler_output** .
But in text_encoder_2 is CLIPTextModelWithProjection, it output is [transformers.models.clip.modeling_clip.CLIPTextModelOutput](https://huggingface.co/docs/transformers/v4.42.0/en/model_doc/clip#transformers.CLIPTextModelWithProjection.forward.returns), it not have **'pooler_output'** ,and in your code
https://github.com/lllyasviel/LayerDiffuse_DiffusersCLI/blob/3061d9aed52a6c52a13fcf2b196c0fef4d727824/diffusers_kdiffusion_sdxl.py#L101, you try to get **pooler_output** in every text_encoder (both **text_encoder** and **text_encoder_2**), so it break!!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with diffusers_kdiffusion_sdxl.py around line 101 and compare the reported outputs from text_encoder and text_encoder_2 under diffusers 0.29.2. Run the SDXL path that triggers the error; done means it no longer raises the reported pooler_output AttributeError for the two encoders.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100