huggingface / huggingface/diffusers
pipeline does not work with conversion to fp16 in the to cuda call
- Ngôn ngữ chính
- Python
- Star
- 34.5k
- Fork
- 7.3k
- Merge trung bình
- 3 ngày 3 giờ
- Pull request đã merge (30 ngày)
- 91
Mô tả
Hi,
i was using and doing some fine-tuning with the Pixart model.
and i found a problem that i could pin it down to:
this code works:
```
pipe2 = PixArtAlphaPipeline.from_pretrained("PixArt-alpha/PixArt-XL-2-512x512", torch_dtype=torch.float16)
pipe2.to("cuda")
image = pipe2(prompt, num_inference_steps=20).images[0]
```
while this does not, it gives out just noise images :
```
pipe1 = PixArtAlphaPipeline.from_pretrained("PixArt-alpha/PixArt-XL-2-512x512")
pipe1.to("cuda", dtype=torch.float16)
image = pipe1(prompt, num_inference_steps=20).images[0]
```
i have looked through the code, and i cannot find any issues so far.
has anyone encountered a similar problem or has tips where to look further?
i am on WSL Ubuntu, diffusers==0.27.2, torch==2.2.2
Hướng dẫn đóng góp
Hướng nghiên cứu
Start by reproducing the two PixArtAlphaPipeline snippets with diffusers 0.27.2 and torch 2.2.2 on WSL Ubuntu, comparing the pipeline state and generated outputs after each CUDA conversion. Done means identifying why the two conversion paths differ and making the dtype conversion produce valid, non-noise images.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- python, pytorch
- Lĩnh vực
- machine-learning
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 25/100