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
Tolga Cangöz
468ae09ed8
Errata - Trim trailing white space in the whole repo ( #8575 )
...
* Trim all the trailing white space in the whole repo
* Remove unnecessary empty places
* make style && make quality
* Trim trailing white space
* trim
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 18:39:15 +05:30
Tolga Cangöz
c375903db5
Errata - Fix typos & improve contributing page ( #8572 )
...
* Fix typos & improve contributing page
* `make style && make quality`
* fix typos
* Fix typo
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 14:13:03 +05:30
Vinh H. Pham
b9d52fca1d
[train_lcm_distill_lora_sdxl.py] Fix the LR schedulers when num_train_epochs is passed in a distributed training env ( #8446 )
...
fix num_train_epochs
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-24 14:09:28 +05:30
drhead
2ada094bff
Add extra performance features for EMAModel, torch._foreach operations and better support for non-blocking CPU offloading ( #7685 )
...
* Add support for _foreach operations and non-blocking to EMAModel
* default foreach to false
* add non-blocking EMA offloading to SD1.5 T2I example script
* fix whitespace
* move foreach to cli argument
* linting
* Update README.md re: EMA weight training
* correct args.foreach_ema
* add tests for foreach ema
* code quality
* add foreach to from_pretrained
* default foreach false
* fix linting
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: drhead <a@a.a>
2024-06-24 14:03:47 +05:30
Sayak Paul
8eb17315c8
[LoRA] get rid of the legacy lora remnants and make our codebase lighter ( #8623 )
...
* get rid of the legacy lora remnants and make our codebase lighter
* fix depcrecated lora argument
* fix
* empty commit to trigger ci
* remove print
* empty
2024-06-21 16:36:05 +05:30
satani99
963ee05d16
Update train_dreambooth_lora_sd3.py ( #8600 )
...
* Update train_dreambooth_lora_sd3.py
* Update train_dreambooth_lora_sd3.py
* Update train_dreambooth_sd3.py
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-20 17:42:24 +05:30
Sayak Paul
a1d55e14ba
Change the default weighting_scheme in the SD3 scripts ( #8639 )
...
* change to logit_normal as the weighting scheme
* sensible default mote
2024-06-19 13:05:26 +01:00
Sayak Paul
23a2cd3337
[LoRA] training fix the position of param casting when loading them ( #8460 )
...
fix the position of param casting when loading them
2024-06-18 14:57:34 +01:00
Sayak Paul
4edde134f6
[SD3 training] refactor the density and weighting utilities. ( #8591 )
...
refactor the density and weighting utilities.
2024-06-18 14:44:38 +01:00
Bagheera
074a7cc3c5
SD3: update default training timestep / loss weighting distribution to logit_normal ( #8592 )
...
Co-authored-by: bghira <bghira@users.github.com >
Co-authored-by: Kashif Rasul <kashif.rasul@gmail.com >
2024-06-18 14:15:19 +01:00
Álvaro Somoza
6bfd13f07a
[SD3 Training] T5 token limit ( #8564 )
...
* initial commit
* default back to 77
* better text
* text correction
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-17 16:32:56 -04:00
spacepxl
8e1b7a084a
Fix the deletion of SD3 text encoders for Dreambooth/LoRA training if the text encoders are not being trained ( #8536 )
...
* Update train_dreambooth_sd3.py to fix TE garbage collection
* Update train_dreambooth_lora_sd3.py to fix TE garbage collection
---------
Co-authored-by: Kashif Rasul <kashif.rasul@gmail.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-16 20:52:33 +01:00
Rafie Walker
6946facf69
Implement SD3 loss weighting ( #8528 )
...
* Add lognorm and cosmap weighting
* Implement mode sampling
* Update examples/dreambooth/train_dreambooth_lora_sd3.py
* Update examples/dreambooth/train_dreambooth_lora_sd3.py
* Update examples/dreambooth/train_dreambooth_sd3.py
* Update examples/dreambooth/train_dreambooth_sd3.py
* Update examples/dreambooth/train_dreambooth_sd3.py
* Update examples/dreambooth/train_dreambooth_lora_sd3.py
* Update examples/dreambooth/train_dreambooth_sd3.py
* Update examples/dreambooth/train_dreambooth_sd3.py
* Update examples/dreambooth/train_dreambooth_lora_sd3.py
* keep timestamp sampling fully on cpu
---------
Co-authored-by: Kashif Rasul <kashif.rasul@gmail.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-16 20:15:50 +01:00
Jonathan Rahn
a899e42fc7
add sentencepiece to requirements.txt for SD3 dreambooth ( #8538 )
...
* add `sentencepiece` requirement for SD3
add `sentencepiece` requirement
* Empty-Commit
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-14 22:48:36 +01:00
Sayak Paul
2e4841ef1e
post release 0.29.0 ( #8492 )
...
post release
2024-06-13 06:14:20 -10:00
Haofan Wang
8bea943714
Update requirements_sd3.txt ( #8521 )
2024-06-13 17:02:17 +01:00
Ameer Azam
0240d4191a
Update README_sd3.md ( #8490 )
...
becasue in Readme it was not correct
train_dreambooth_sd3.py to train_dreambooth_lora_sd3
2024-06-12 21:08:36 +01:00
Dhruv Nair
04717fd861
Add Stable Diffusion 3 ( #8483 )
...
* up
* add sd3
* update
* update
* add tests
* fix copies
* fix docs
* update
* add dreambooth lora
* add LoRA
* update
* update
* update
* update
* import fix
* update
* Update src/diffusers/pipelines/stable_diffusion_3/pipeline_stable_diffusion_3.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* import fix 2
* update
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* update
* update
* update
* fix ckpt id
* fix more ids
* update
* missing doc
* Update src/diffusers/schedulers/scheduling_flow_match_euler_discrete.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update src/diffusers/schedulers/scheduling_flow_match_euler_discrete.py
Co-authored-by: YiYi Xu <yixu310@gmail.com >
* Update docs/source/en/api/pipelines/stable_diffusion/stable_diffusion_3.md
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* Update docs/source/en/api/pipelines/stable_diffusion/stable_diffusion_3.md
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* update'
* fix
* update
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
* Update src/diffusers/models/autoencoders/autoencoder_kl.py
* note on gated access.
* requirements
* licensing
---------
Co-authored-by: sayakpaul <spsayakpaul@gmail.com >
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-06-12 20:44:00 +01:00
Sayak Paul
d457beed92
Update README.md to update the MaPO project ( #8470 )
...
Update README.md
2024-06-11 10:10:45 +01:00
Tolga Cangöz
98730c5dd7
Errata ( #8322 )
...
* Fix typos
* Trim trailing whitespaces
* Remove a trailing whitespace
* chore: Update MarigoldDepthPipeline checkpoint to prs-eth/marigold-lcm-v1-0
* Revert "chore: Update MarigoldDepthPipeline checkpoint to prs-eth/marigold-lcm-v1-0"
This reverts commit fd742b30b4 .
* pokemon -> naruto
* `DPMSolverMultistep` -> `DPMSolverMultistepScheduler`
* Improve Markdown stylization
* Improve style
* Improve style
* Refactor pipeline variable names for consistency
* up style
2024-06-05 13:59:09 -07:00
Hzzone
d3881f35b7
Gligen training ( #7906 )
...
* add training code of gligen
* fix code quality tests.
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-06-05 16:26:42 +04:00
satani99
352d96eb82
Modularize train_text_to_image_lora_sdxl inferencing during and after training in example ( #8335 )
...
* Modularized the train_lora_sdxl file
* Modularized the train_lora_sdxl file
* Modularized the train_lora_sdxl file
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-31 04:52:22 +05:30
Genius Patrick
3511a9623f
fix(training): lr scheduler doesn't work properly in distributed scenarios ( #8312 )
2024-05-30 15:23:19 +05:30
Tolga Cangöz
a2ecce26bc
Fix Copying Mechanism typo/bug ( #8232 )
...
* Fix copying mechanism typos
* fix copying mecha
* Revert, since they are in TODO
* Fix copying mechanism
2024-05-29 09:37:18 -07:00
satani99
3bc3b48c10
Modularize train_text_to_image_lora SD inferencing during and after training in example ( #8283 )
...
* Modularized the train_lora file
* Modularized the train_lora file
* Modularized the train_lora file
* Modularized the train_lora file
* Modularized the train_lora file
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-29 10:08:02 +05:30
Sayak Paul
581d8aacf7
post release v0.28.0 ( #8286 )
...
* post release v0.28.0
* style
2024-05-29 07:13:22 +05:30
Sajad Norouzi
67bef2027c
Add Kohya fix to SD pipeline for high resolution generation ( #7633 )
...
add kohya high resolution fix.
2024-05-28 10:00:04 -10:00
Tolga Cangöz
0ab63ff647
Fix CPU Offloading Usage & Typos ( #8230 )
...
* Fix typos
* Fix `pipe.enable_model_cpu_offload()` usage
* Fix cpu offloading
* Update numbers
2024-05-24 11:25:29 -07:00
Tolga Cangöz
db33af065b
Fix a grammatical error in the raise messages ( #8272 )
...
Fix grammatical error
2024-05-24 11:15:00 -07:00
Yifan Zhou
46a9db0336
[Community Pipeline] FRESCO: Spatial-Temporal Correspondence for Zero-Shot Video Translation ( #8239 )
...
* code and doc
* update paper link
* remove redundant codes
* add example video
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-24 14:44:20 +05:30
Sai-Suraj-27
df2bc5ef28
fix: Fixed few docstrings according to the Google Style Guide ( #7717 )
...
Fixed few docstrings according to the Google Style Guide.
2024-05-20 10:26:05 -07:00
Alphin Jain
1221b28eac
Fix AttributeError in train_lcm_distill_lora_sdxl_wds.py ( #7923 )
...
Fix conditional teacher model check in train_lcm_distill_lora_sdxl_wds.py
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-16 15:49:54 +05:30
Sai-Suraj-27
2afea72d29
refactor: Refactored code by Merging isinstance calls ( #7710 )
...
* Merged isinstance calls to make the code simpler.
* Corrected formatting errors using ruff.
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: YiYi Xu <yixu310@gmail.com >
2024-05-15 18:33:19 -10:00
Isamu Isozaki
d27e996ccd
Adding VQGAN Training script ( #5483 )
...
* Init commit
* Removed einops
* Added default movq config for training
* Update explanation of prompts
* Fixed inheritance of discriminator and init_tracker
* Fixed incompatible api between muse and here
* Fixed output
* Setup init training
* Basic structure done
* Removed attention for quick tests
* Style fixes
* Fixed vae/vqgan styles
* Removed redefinition of wandb
* Fixed log_validation and tqdm
* Nothing commit
* Added commit loss to lookup_from_codebook
* Update src/diffusers/models/vq_model.py
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* Adding perliminary README
* Fixed one typo
* Local changes
* Fixed main issues
* Merging
* Update src/diffusers/models/vq_model.py
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* Testing+Fixed bugs in training script
* Some style fixes
* Added wandb to docs
* Fixed timm test
* get testing suite ready.
* remove return loss
* remove return_loss
* Remove diffs
* Remove diffs
* fix ruff format
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-05-15 08:47:12 +05:30
Jingyang Zhang
69fdb8720f
[Pipeline] Adding BoxDiff to community examples ( #7947 )
...
add boxdiff to community examples
2024-05-14 11:18:29 -10:00
bssrdf
cdda94f412
fix VAE loading issue in train_dreambooth ( #7632 )
...
* fixed vae loading issue #7619
* rerun make style && make quality
* bring back model_has_vae and add change \ to / in config_file_name on windows os to make match work
* add missing import platform
* bring back import model_info
* make config_file_name OS independent
* switch to using Path.as_posix() to resolve OS dependence
* improve style
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
Co-authored-by: bssrdf <bssrdf@gmail.com >
Co-authored-by: Dhruv Nair <dhruv.nair@gmail.com >
2024-05-14 08:19:53 +05:30
dependabot[bot]
5b830aa356
Bump transformers from 4.36.0 to 4.38.0 in /examples/research_projects/realfill ( #7635 )
...
Bump transformers in /examples/research_projects/realfill
Bumps [transformers](https://github.com/huggingface/transformers ) from 4.36.0 to 4.38.0.
- [Release notes](https://github.com/huggingface/transformers/releases )
- [Commits](https://github.com/huggingface/transformers/compare/v4.36.0...v4.38.0 )
---
updated-dependencies:
- dependency-name: transformers
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-14 08:17:06 +05:30
Kohei
9e7bae9881
Update requirements.txt for text_to_image ( #7892 )
...
Update requirements.txt
If the datasets library is old, it will not read the metadata.jsonl and the label will default to an integer of type int.
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-14 08:09:12 +05:30
HelloWorldBeginner
98ba18ba55
Add Ascend NPU support for SDXL. ( #7916 )
...
Co-authored-by: mhh001 <mahonghao1@huawei.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-12 13:34:23 +02:00
HelloWorldBeginner
0267c5233a
fix bugs when using deepspeed in sdxl ( #7917 )
...
fix bugs when using deepspeed
Co-authored-by: mhh001 <mahonghao1@huawei.com >
2024-05-11 20:49:09 +02:00
Mark Van Aken
be4afa0bb4
#7535 Update FloatTensor type hints to Tensor ( #7883 )
...
* find & replace all FloatTensors to Tensor
* apply formatting
* Update torch.FloatTensor to torch.Tensor in the remaining files
* formatting
* Fix the rest of the places where FloatTensor is used as well as in documentation
* formatting
* Update new file from FloatTensor to Tensor
2024-05-10 09:53:31 -10:00
Tolga Cangöz
c1c42698c9
Remove dead code and fix f-string issue ( #7720 )
...
* Remove dead code
* PylancereportGeneralTypeIssues: Strings nested within an f-string cannot use the same quote character as the f-string prior to Python 3.12.
* Remove dead code
2024-05-08 13:15:28 -10:00
Hyoungwon Cho
c2217142bd
Modification on the PAG community pipeline (re) ( #7876 )
...
* edited_pag_implementation
* update
---------
Co-authored-by: yiyixuxu <yixu310@gmail.com >
2024-05-07 16:35:15 -10:00
Bagheera
8edaf3b79c
7879 - adjust documentation to use naruto dataset, since pokemon is now gated ( #7880 )
...
* 7879 - adjust documentation to use naruto dataset, since pokemon is now gated
* replace references to pokemon in docs
* more references to pokemon replaced
* Japanese translation update
---------
Co-authored-by: bghira <bghira@users.github.com >
2024-05-07 09:36:39 -07:00
HelloWorldBeginner
58237364b1
Add Ascend NPU support for SDXL fine-tuning and fix the model saving bug when using DeepSpeed. ( #7816 )
...
* Add Ascend NPU support for SDXL fine-tuning and fix the model saving bug when using DeepSpeed.
* fix check code quality
* Decouple the NPU flash attention and make it an independent module.
* add doc and unit tests for npu flash attention.
---------
Co-authored-by: mhh001 <mahonghao1@huawei.com >
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-03 08:14:34 -10:00
YiYi Xu
21a7ff12a7
update the logic of is_sequential_cpu_offload ( #7788 )
...
* up
* add comment to the tests + fix dit
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-05-01 06:25:57 -10:00
Linoy Tsaban
26a7851e1e
Add B-Lora training option to the advanced dreambooth lora script ( #7741 )
...
* add blora
* add blora
* add blora
* add blora
* little changes
* little changes
* remove redundancies
* fixes
* add B LoRA to readme
* style
* inference
* defaults + path to loras+ generation
* minor changes
* style
* minor changes
* minor changes
* blora arg
* added --lora_unet_blocks
* style
* Update examples/advanced_diffusion_training/README.md
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
* add commit hash to B-LoRA repo cloneing
* change inference, remove cloning
* change inference, remove cloning
add section about configureable unet blocks
* change inference, remove cloning
add section about configureable unet blocks
* Apply suggestions from code review
---------
Co-authored-by: Sayak Paul <spsayakpaul@gmail.com >
2024-04-30 09:46:30 +05:30
Nilesh
235d34cf56
Check for latents, before calling prepare_latents - sdxlImg2Img ( #7582 )
...
* Check for latents, before calling prepare_latents - sdxlImg2Img
* Added latents check for all the img2img pipeline
* Fixed silly mistake while checking latents as None
2024-04-28 14:53:29 -10:00