Closed suzukimain closed 4 months ago
Cc: @DN6
Hi, thanks for reporting. I tested this and It works with the 0.28.2 version. It's weird that it doesn't work for you. I suggest you try uninstalling diffusers and then install it again.
- 🤗 Diffusers version: 0.28.2
from diffusers import StableDiffusionPipeline
pipe = StableDiffusionPipeline.from_single_file(
"https://huggingface.co/gsdf/Counterfeit-V2.5/blob/main/Counterfeit-V2.5_fp16.safetensors"
).to("cuda")
image = pipe(prompt="a happy capybara jumping on the street").images[0]
image.save("result.png")
Thank you for your swift response. I tried again, but it fails.
https://github.com/huggingface/diffusers/assets/131413573/4bde0c67-dd98-448f-8617-dd710296fef0
Detailed log.
RuntimeError Traceback (most recent call last)
oh yeah, you're right, in colab it gives an error but locally it's just a warning:
local:
Some weights of the model checkpoint were not used when initializing CLIPTextModel:
['text_model.embeddings.position_ids']
colab:
RuntimeError: Error(s) in loading state_dict for CLIPTextModel:
Unexpected key(s) in state_dict: "text_model.embeddings.position_ids".
I have the same pytorch and cuda version as in colab, the only difference is the python version. We'll have to wait for @DN6 for a solution it seems.
Interesting, I installed transformers from source !pip install git+https://github.com/huggingface/transformers.git
in the colab and I got a different error:
SingleFileComponentError: Failed to load CLIPTextModel. Weights for this component appear to be missing in the checkpoint.
Please load the component before passing it in as an argument to `from_single_file`.
in the meantime, since that repo has a version in the diffusers format, why not use it like this?
pipe = StableDiffusionPipeline.from_pretrained("gsdf/Counterfeit-V2.5").to("cuda")
The same issue was also discussed here.
However, I'm not used to making pull requests, so if I'm wrong somewhere, please point it out.
Fixed in #8462 and I'll close it. Thank you!
Describe the bug
Versioning diffusers to 0.29.0.dev0 did not solve the problem.
Reproduction
pip install diffusers from diffusers import StableDiffusionPipeline pipe = StableDiffusionPipeline.from_single_file("https://huggingface.co/gsdf/Counterfeit-V2.5/blob/main/Counterfeit-V2.5_fp16.safetensors")
Logs
System Info
Who can help?
No response