Closed
Description
Describe the bug
The SD3IPAdapterMixin
incorrectly applies .to(self.device, dtype=self.dtype)
to SiglipImageProcessor
, which does not have a .to()
method.
diffusers/src/diffusers/loaders/ip_adapter.py
Lines 807 to 809 in b88fef4
This causes an AttributeError
when loading an IP-Adapter with an image encoder.
Reproduction
import torch
from diffusers import StableDiffusion3Pipeline
pipe = StableDiffusion3Pipeline.from_pretrained("stabilityai/stable-diffusion-3-medium-diffusers", torch_dtype=torch.float16)
pipe.load_ip_adapter("InstantX/SD3.5-Large-IP-Adapter", "ip-adapter.bin", image_encoder_folder="google/siglip-base-patch16-224")
Logs
AttributeError: 'SiglipImageProcessor' object has no attribute 'to'
System Info
- 🤗 Diffusers version: 0.32.2
- Platform: Windows-10-10.0.26100-SP0
- Running on Google Colab?: No
- Python version: 3.10.11
- PyTorch version (GPU?): 2.6.0+cpu (False)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Huggingface_hub version: 0.29.1
- Transformers version: 4.49.0
- Accelerate version: 1.4.0
- PEFT version: not installed
- Bitsandbytes version: not installed
- Safetensors version: 0.5.3
- xFormers version: not installed
- Accelerator: NA
- Using GPU in script?:
- Using distributed or parallel set-up in script?:
Who can help?
No response