Yoach Lacombe
ea1b4ea7ca
Fix Stable Audio repository id ( #9016 )
...
Fix Stable Audio repo id
2024-07-30 23:17:44 +05:30
Aryan
e5b94b4c57
[core] Move community AnimateDiff ControlNet to core ( #8972 )
...
* add animatediff controlnet to core
* make style; remove unused method
* fix copied from comment
* add tests
* changes to make tests work
* add utility function to load videos
* update docs
* update pipeline example
* make style
* update docs with example
* address review comments
* add latest freeinit test from #8969
* LoraLoaderMixin -> StableDiffusionLoraLoaderMixin
* fix docs
* Update src/diffusers/utils/loading_utils.py
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
* fix: variable out of scope
---------
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-07-30 17:10:37 +05:30
Yoach Lacombe
69e72b1dd1
Stable Audio integration ( #8716 )
...
* WIP modeling code and pipeline
* add custom attention processor + custom activation + add to init
* correct ProjectionModel forward
* add stable audio to __initèè
* add autoencoder and update pipeline and modeling code
* add half Rope
* add partial rotary v2
* add temporary modfis to scheduler
* add EDM DPM Solver
* remove TODOs
* clean GLU
* remove att.group_norm to attn processor
* revert back src/diffusers/schedulers/scheduling_dpmsolver_multistep.py
* refactor GLU -> SwiGLU
* remove redundant args
* add channel multiples in autoencoder docstrings
* changes in docsrtings and copyright headers
* clean pipeline
* further cleaning
* remove peft and lora and fromoriginalmodel
* Delete src/diffusers/pipelines/stable_audio/diffusers.code-workspace
* make style
* dummy models
* fix copied from
* add fast oobleck tests
* add brownian tree
* oobleck autoencoder slow tests
* remove TODO
* fast stable audio pipeline tests
* add slow tests
* make style
* add first version of docs
* wrap is_torchsde_available to the scheduler
* fix slow test
* test with input waveform
* add input waveform
* remove some todos
* create stableaudio gaussian projection + make style
* add pipeline to toctree
* fix copied from
* make quality
* refactor timestep_features->time_proj
* refactor joint_attention_kwargs->cross_attention_kwargs
* remove forward_chunk
* move StableAudioDitModel to transformers folder
* correct convert + remove partial rotary embed
* apply suggestions from yiyixuxu -> removing attn.kv_heads
* remove temb
* remove cross_attention_kwargs
* further removal of cross_attention_kwargs
* remove text encoder autocast to fp16
* continue removing autocast
* make style
* refactor how text and audio are embedded
* add paper
* update example code
* make style
* unify projection model forward + fix device placement
* make style
* remove fuse qkv
* apply suggestions from review
* Update src/diffusers/pipelines/stable_audio/pipeline_stable_audio.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* make style
* smaller models in fast tests
* pass sequential offloading fast tests
* add docs for vae and autoencoder
* make style and update example
* remove useless import
* add cosine scheduler
* dummy classes
* cosine scheduler docs
* better description of scheduler
---------
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-07-30 15:29:06 +05:30
Γlvaro Somoza
73acebb8cf
[Kolors] Add IP Adapter ( #8901 )
...
* initial draft
* apply suggestions
* fix failing test
* added ipa to img2img
* add docs
* apply suggestions
2024-07-26 14:25:44 -04:00
Aryan
5c53ca5ed8
[core] AnimateDiff SparseCtrl ( #8897 )
...
* initial sparse control model draft
* remove unnecessary implementation
* copy animatediff pipeline
* remove deprecated callbacks
* update
* update pipeline implementation progress
* make style
* make fix-copies
* update progress
* add partially working pipeline
* remove debug prints
* add model docs
* dummy objects
* improve motion lora conversion script
* fix bugs
* update docstrings
* remove unnecessary model params; docs
* address review comment
* add copied from to zero_module
* copy animatediff test
* add fast tests
* update docs
* update
* update pipeline docs
* fix expected slice values
* fix license
* remove get_down_block usage
* remove temporal_double_self_attention from get_down_block
* update
* update docs with org and documentation images
* make from_unet work in sparsecontrolnetmodel
* add latest freeinit test from #8969
* make fix-copies
* LoraLoaderMixin -> StableDiffsuionLoraLoaderMixin
2024-07-26 17:46:05 +05:30
Aryan
57a021d5e4
[fix] FreeInit step index out of bounds ( #8969 )
...
* fix step index out of bounds
* add test for free_init with different schedulers
* add test to vid2vid and pia
2024-07-26 16:45:55 +05:30
Sayak Paul
d87fe95f90
[Chore] add LoraLoaderMixin to the inits ( #8981 )
...
* introduce to promote reusability.
* up
* add more tests
* up
* remove comments.
* fix fuse_nan test
* clarify the scope of fuse_lora and unfuse_lora
* remove space
* rewrite fuse_lora a bit.
* feedback
* copy over load_lora_into_text_encoder.
* address dhruv's feedback.
* fix-copies
* fix issubclass.
* num_fused_loras
* fix
* fix
* remove mapping
* up
* fix
* style
* fix-copies
* change to SD3TransformerLoRALoadersMixin
* Apply suggestions from code review
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
* up
* handle wuerstchen
* up
* move lora to lora_pipeline.py
* up
* fix-copies
* fix documentation.
* comment set_adapters().
* fix-copies
* fix set_adapters() at the model level.
* fix?
* fix
* loraloadermixin.
---------
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-07-26 08:59:33 +05:30
YiYi Xu
62863bb1ea
Revert "[LoRA] introduce LoraBaseMixin to promote reusability." ( #8976 )
...
Revert "[LoRA] introduce LoraBaseMixin to promote reusability. (#8774 )"
This reverts commit 527430d0a4 .
2024-07-25 09:10:35 -10:00
Sayak Paul
527430d0a4
[LoRA] introduce LoraBaseMixin to promote reusability. ( #8774 )
...
* introduce to promote reusability.
* up
* add more tests
* up
* remove comments.
* fix fuse_nan test
* clarify the scope of fuse_lora and unfuse_lora
* remove space
* rewrite fuse_lora a bit.
* feedback
* copy over load_lora_into_text_encoder.
* address dhruv's feedback.
* fix-copies
* fix issubclass.
* num_fused_loras
* fix
* fix
* remove mapping
* up
* fix
* style
* fix-copies
* change to SD3TransformerLoRALoadersMixin
* Apply suggestions from code review
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
* up
* handle wuerstchen
* up
* move lora to lora_pipeline.py
* up
* fix-copies
* fix documentation.
* comment set_adapters().
* fix-copies
* fix set_adapters() at the model level.
* fix?
* fix
---------
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-07-25 21:40:58 +05:30
Aryan
3ae0ee88d3
[tests] speed up animatediff tests ( #8846 )
...
* speed up animatediff tests
* fix pia test_ip_adapter_single
* fix tests/pipelines/pia/test_pia.py::PIAPipelineFastTests::test_dict_tuple_outputs_equivalent
* update
* fix ip adapter tests
* skip test_from_pipe_consistent_config tests
* fix prompt_embeds test
* update test_from_pipe_consistent_config tests
* fix expected_slice values
* remove temporal_norm_num_groups from UpBlockMotion
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-07-25 17:35:43 +05:30
Sayak Paul
d8bcb33f4b
[Tests] fix slices of 26 tests (first half) ( #8959 )
...
* check for assertions.
* update with correct slices.
* okay
* style
* get it ready
* update
* update
* update
---------
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-07-25 14:56:49 +05:30
Dhruv Nair
93983b6780
[CI] Skip flaky download tests in PR CI ( #8945 )
...
update
2024-07-24 09:25:06 +05:30
Sayak Paul
41b705f42d
remove residual i from auraflow. ( #8949 )
...
* remove residual i.
* rename to aura_flow in pipeline test
2024-07-24 07:31:54 +05:30
Sayak Paul
50d21f7c6a
[Core] fix QKV fusion for attention ( #8829 )
...
* start debugging the problem,
* start
* fix
* fix
* fix imports.
* handle hunyuan
* remove residuals.
* add a check for making sure there's appropriate procs.
* add more rigor to the tests.
* fix test
* remove redundant check
* fix-copies
* move check_qkv_fusion_matches_attn_procs_length and check_qkv_fusion_processors_exist.
2024-07-24 06:52:19 +05:30
Vinh H. Pham
7a95f8d9d8
[Tests] Improve transformers model test suite coverage - Temporal Transformer ( #8932 )
...
* add test for temporal transformer
* remove unused variable
* fix code quality
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-07-23 15:36:30 +05:30
Aritra Roy Gosthipaty
8b21feed42
[Tests] reduce the model size in the audioldm2 fast test ( #7846 )
...
* chore: initial model size reduction
* chore: fixing expected values for failing tests
* requested edits
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-07-23 14:34:07 +05:30
Sayak Paul
af400040f5
[Tests] proper skipping of request caching test ( #8908 )
...
proper skipping of request caching test
2024-07-22 12:52:57 -10:00
shinetzh
3b04cdc816
fix loop bug in SlicedAttnProcessor ( #8836 )
...
* fix loop bug in SlicedAttnProcessor
---------
Co-authored-by: neoshang <neoshang@tencent.com >
2024-07-19 18:14:29 -10:00
Sayak Paul
0f09b01ab3
[Core] fix: shard loading and saving when variant is provided. ( #8869 )
...
fix: shard loading and saving when variant is provided.
2024-07-17 08:26:28 +05:30
Tolga CangΓΆz
e87bf62940
[Cont'd] Add the SDE variant of ~~DPM-Solver~~ and DPM-Solver++ to DPM Single Step ( #8269 )
...
* Add the SDE variant of DPM-Solver and DPM-Solver++ to DPM Single Step
---------
Co-authored-by: cmdr2 <secondary.cmdr2@gmail.com >
2024-07-16 15:40:02 -10:00
Aryan
bbd2f9d4e9
[tests] fix typo in pag tests ( #8845 )
...
* fix typo in pag tests
* fix typo
2024-07-12 17:41:34 +05:30
NguyΓͺΜn CΓ΄ng TuΜ Anh
d704b3bf8c
add PAG support sd15 controlnet ( #8820 )
...
* add pag support sd15 controlnet
* fix quality import
* remove unecessary import
* remove if state
* fix tests
* remove useless function
* add sd1.5 controlnet pag docs
---------
Co-authored-by: anhnct8 <anhnct8@fpt.com >
2024-07-12 15:42:56 +05:30
Dhruv Nair
11d18f3217
Add single file loading support for AnimateDiff ( #8819 )
...
* update
* update
* update
* update
2024-07-12 09:51:57 +05:30
Sayak Paul
2261510bbc
[Core] Add AuraFlow ( #8796 )
...
* add lavender flow transformer
---------
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-07-11 08:50:19 -10:00
Γlvaro Somoza
87b9db644b
[Core] Add Kolors ( #8812 )
...
* initial draft
2024-07-11 06:09:17 -10:00
Xin Ma
b8cf84a3f9
Latte: Latent Diffusion Transformer for Video Generation ( #8404 )
...
* add Latte to diffusers
* remove print
* remove print
* remove print
* remove unuse codes
* remove layer_norm_latte and add a flag
* remove layer_norm_latte and add a flag
* update latte_pipeline
* update latte_pipeline
* remove unuse squeeze
* add norm_hidden_states.ndim == 2: # for Latte
* fixed test latte pipeline bugs
* fixed test latte pipeline bugs
* delete sh
* add doc for latte
* add licensing
* Move Transformer3DModelOutput to modeling_outputs
* give a default value to sample_size
* remove the einops dependency
* change norm2 for latte
* modify pipeline of latte
* update test for Latte
* modify some codes for latte
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* modify for Latte pipeline
* video_length -> num_frames; update prepare_latents copied from
* make fix-copies
* make style
* typo: videe -> video
* update
* modify for Latte pipeline
* modify latte pipeline
* modify latte pipeline
* modify latte pipeline
* modify latte pipeline
* modify for Latte pipeline
* Delete .vscode directory
* make style
* make fix-copies
* add latte transformer 3d to docs _toctree.yml
* update example
* reduce frames for test
* fixed bug of _text_preprocessing
* set num frame to 1 for testing
* remove unuse print
* add text = self._clean_caption(text) again
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: YiYi Xu <yixu310@gmail.com >
Co-authored-by: Aryan <contact.aryanvs@gmail.com >
Co-authored-by: Aryan <aryan@huggingface.co >
2024-07-11 15:06:22 +05:30
Sayak Paul
a785992c1d
[Tests] fix more sharding tests ( #8797 )
...
* fix
* fix
* ugly
* okay
* fix more
* fix oops
2024-07-09 13:09:36 +05:30
Xu Cao
35cc66dc4c
Add pipeline_stable_diffusion_3_inpaint.py for SD3 Inference ( #8709 )
...
* Add pipeline_stable_diffusion_3_inpaint
---------
Co-authored-by: Xu Cao <xucao2@jrehg-work-01.cs.illinois.edu >
Co-authored-by: IrohXu <irohcao@gmail.com >
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-07-08 15:53:02 -10:00
Tolga CangΓΆz
57084dacc5
Remove unnecessary lines ( #8569 )
...
* Remove unused line
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-07-08 10:42:02 -10:00
PommesPeter
98388670d2
[Alpha-VLLM Team] Add Lumina-T2X to diffusers ( #8652 )
...
---------
Co-authored-by: zhuole1025 <zhuole1025@gmail.com >
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-07-07 17:12:09 -10:00
YiYi Xu
9e9ed353a2
fix loading sharded checkpoints from subfolder ( #8798 )
...
* fix load sharded checkpoints from subfolder{
* style
* os.path.join
* add a small test
---------
Co-authored-by: sayakpaul <spsayakpaul@gmail.com >
2024-07-06 11:32:04 -10:00
Dhruv Nair
0bab9d6be7
[Single File] Allow loading T5 encoder in mixed precision ( #8778 )
...
* update
* update
* update
* update
2024-07-05 10:29:38 +05:30
Sayak Paul
31adeb41cd
[Tests] fix sharding tests ( #8764 )
...
fix sharding tests
2024-07-04 08:50:59 +05:30
Aryan
a7b9634e95
Fix minor bug in SD3 img2img test ( #8779 )
...
fix minor bug in sd3 img2img
2024-07-03 07:45:37 -10:00
Sayak Paul
984d340534
Revert "[LoRA] introduce LoraBaseMixin to promote reusability." ( #8773 )
...
Revert "[LoRA] introduce `LoraBaseMixin` to promote reusability. (#8670 )"
This reverts commit a2071a1837 .
2024-07-03 07:05:01 +05:30
Sayak Paul
a2071a1837
[LoRA] introduce LoraBaseMixin to promote reusability. ( #8670 )
...
* introduce to promote reusability.
* up
* add more tests
* up
* remove comments.
* fix fuse_nan test
* clarify the scope of fuse_lora and unfuse_lora
* remove space
2024-07-03 07:04:37 +05:30
Shauray Singh
8690e8b9d6
add PAG support for SD architecture ( #8725 )
...
* add pag to sd pipelines
2024-06-29 09:26:11 -10:00
Dhruv Nair
150142c537
[Tests] Fix precision related issues in slow pipeline tests ( #8720 )
...
update
2024-06-28 08:13:46 +05:30
Mathis Koroglu
3e0d128da7
Motion Model / Adapter versatility ( #8301 )
...
* Motion Model / Adapter versatility
- allow to use a different number of layers per block
- allow to use a different number of transformer per layers per block
- allow a different number of motion attention head per block
- use dropout argument in get_down/up_block in 3d blocks
* Motion Model added arguments renamed & refactoring
* Add test for asymmetric UNetMotionModel
2024-06-27 11:11:29 +05:30
vincedovy
a536e775fb
Fix json WindowsPath crash ( #8662 )
...
* Add check for WindowsPath in to_json_string
On Windows, os.path.join returns a WindowsPath. to_json_string does not convert this from a WindowsPath to a string. Added check for WindowsPath to to_json_saveable.
* Remove extraneous convert to string in test_check_path_types (tests/others/test_config.py)
* Fix style issues in tests/others/test_config.py
* Add unit test to test_config.py to verify that PosixPath and WindowsPath (depending on system) both work when converted to JSON
* Remove distinction between PosixPath and WindowsPath in ConfigMixIn.to_json_string(). Conditional now tests for Path, and uses Path.as_posix() to convert to string.
---------
Co-authored-by: Vincent Dovydaitis <vincedovy@gmail.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-27 10:30:55 +05:30
Dhruv Nair
effe4b9784
Update xformers SD3 test ( #8712 )
...
update
2024-06-26 10:24:27 -10:00
XCL
fa2abfdb03
[Tencent Hunyuan Team] Add Hunyuan-DiT ControlNet Inference ( #8694 )
...
* add controlnet support
---------
Co-authored-by: xingchaoliu <xingchaoliu@tencent.com >
Co-authored-by: yiyixuxu <yixu310@gmail,com>
2024-06-26 00:43:03 -10:00
Dhruv Nair
0f0b531827
Add decorator for compile tests ( #8703 )
...
* update
* update
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-26 11:26:47 +05:30
YiYi Xu
540399f540
add PAG support ( #7944 )
...
* first draft
---------
Co-authored-by: yiyixuxu <yixu310@gmail,com>
Co-authored-by: Junhwa Song <ethan9867@gmail.com >
Co-authored-by: Ahn Donghoon (μλν / suno) <suno.vivid@gmail.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com >
2024-06-25 08:40:02 -10:00
Sayak Paul
f088027e93
[Marigold tests] add is_flaky decorator to some Marigold tests ( #8696 )
...
okay
2024-06-25 06:27:28 -10:00
Linoy Tsaban
c6e08ecd46
[Sd3 Dreambooth LoRA] Add text encoder training for the clip encoders ( #8630 )
...
* add clip text-encoder training
* no dora
* text encoder traing fixes
* text encoder traing fixes
* text encoder training fixes
* text encoder training fixes
* text encoder training fixes
* text encoder training fixes
* add text_encoder layers to save_lora
* style
* fix imports
* style
* fix text encoder
* review changes
* review changes
* review changes
* minor change
* add lora tag
* style
* add readme notes
* add tests for clip encoders
* style
* typo
* fixes
* style
* Update tests/lora/test_lora_layers_sd3.py
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* Update examples/dreambooth/README_sd3.md
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* minor readme change
---------
Co-authored-by: YiYi Xu <yixu310@gmail.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-25 18:00:19 +05:30
Sayak Paul
4ad7a1f5fd
[Chore] create a utility for calculating the expected number of shards. ( #8692 )
...
create a utility for calculating the expected number of shards.
2024-06-25 17:05:39 +05:30
Tolga CangΓΆz
f040c27d4c
Errata - Fix typos and improve style ( #8571 )
...
* Fix typos
* Fix typos & up style
* chore: Update numbers
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 10:07:22 -07:00
Tolga CangΓΆz
138fac703a
Discourage using deprecated revision parameter ( #8573 )
...
* Discourage using `revision`
* `make style && make quality`
* Refactor code to use 'variant' instead of 'revision'
* `revision="bf16"` -> `variant="bf16"`
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 10:06:49 -07:00
Dong
3fca52022f
π¨ fix xl playground device ( #8550 )
...
* π¨ fix xl playground device
* π¨ run `make fix-copies`
* π¨ run `make fix-copies`
* edit xl_controlnet_img2img file
* edit playground img2img test slow
* Update tests/pipelines/stable_diffusion_xl/test_stable_diffusion_xl_img2img.py
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 16:49:55 +05:30