diffusers
3467efa6 - Add Ideogram4LoraLoaderMixin (LoRA loading for Ideogram4) (#13921)

Commit
24 days ago
Add Ideogram4LoraLoaderMixin (LoRA loading for Ideogram4) (#13921) * add Ideogram4LoraLoaderMixin * Support loading non-diffusers Ideogram4 LoRA checkpoints (#13919) support loading non-diffusers Ideogram4 LoRAs * add Ideogram4 LoRA loader tests * support call-time LoRA scaling via attention_kwargs in Ideogram4 * fix and un-skip Ideogram4 LoRA loader tests * document attention_kwargs in Ideogram4 forward and pipeline * style Ideogram4 attention_kwargs docstrings * fix Ideogram4 LoRA loader CI test failures - pipeline: run the text encoder on its parameters' current device, then move features to the execution device, so encode_prompt works under enable_model_cpu_offload. The pipeline calls the text encoder's submodules directly to tap intermediate layers, which bypasses accelerate's onload hook, so the weights stay on CPU while inputs are on the execution device. Fixes test_lora_loading_model_cpu_offload. - tests: override test_lora_fuse_nan to corrupt a weight under Ideogram4's `layers` tower (the base test probes transformer_blocks/blocks/etc.). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * address review nits on Ideogram4 LoRA loader - pipeline: clarify the te_device comment (per review) — explain the CpuOffload hook attaches to forward, why submodule calls bypass it, and that te_device is the offload device under enable_model_cpu_offload. - tests: drop the unused `import sys` and `sys.path.append(".")`. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-authored-by: Sayak Paul <spsayakpaul@gmail.com> Co-authored-by: dg845 <58458699+dg845@users.noreply.github.com>
Author
Parents
Loading