7ee3fef2db
cleanup: better var names for the ip adapter weight collection block
2024-04-16 04:23:50 +05:30
a148c4322c
fix: IP Adapter weights being incorrectly applied
...
They were being overwritten rather than being appended
2024-04-16 04:10:41 +05:30
5f6c6abf9c
chore: change IPAdapterAttentionWeights to a dataclass
2024-04-15 23:38:55 +05:30
8426f1e7b2
fix(experimental): Possible fix for conflict with regional embed length mismatch
...
Pushing this so people can test it out and see if this needs to be handled in a different way.
2024-04-14 12:19:19 +05:30
9cb0f63c44
refactor: fix a bunch of type issues in custom_attention
2024-04-13 14:17:25 +05:30
d4393e4170
chore: linter fixes
2024-04-13 12:14:45 +05:30
6ea183f0d4
wip: Initial Implementation IP Adapter Style & Comp Modes
2024-04-13 11:09:45 +05:30
f9af32a6d1
Fix the padding behavior when max-pooling regional IP-Adapter masks to mirror the downscaling behavior of SD and SDXL. Prior to this change, denoising with input latent dimensions that were not evenly divisible by 8 would raise an exception.
2024-04-09 16:50:43 -04:00
fba40eb1bd
Fix the padding behavior when max-pooling regional prompt masks to mirror the downscaling behavior of SD and SDXL. Prior to this change, denoising with input latent dimensions that were not evenly divisible by 8 would raise an exception.
2024-04-09 16:50:43 -04:00
0c6dd32ece
(minor) Fix IP-Adapter conditional logic in CustomAttnProcessor2_0.
2024-04-09 15:06:51 -04:00
0bdbfd4d1d
Add support for IP-Adapter masks.
2024-04-09 15:06:51 -04:00
2e27ed5f3d
Pass IP-Adapter scales through the cross_attn_kwargs pathway, since they are the same for all attention layers. This change also helps to prepare for adding IP-Adapter region masks.
2024-04-09 15:06:51 -04:00
4a828818da
Remove support for Prompt-to-Prompt cross-attention control (aka .swap()). This feature is not widely used. It does not work with SDXL and is incompatible with IP-Adapter and regional prompting. The implementation is also intertwined with both text embedding and the UNet attention layers, resulting in a high maintenance burden. For all of these reasons, we have decided to drop support.
2024-04-09 10:57:02 -04:00
182810337c
Add utility to_standard_float_mask(...) to convert various mask formats to a standardized format.
2024-04-09 08:12:12 -04:00
75ef473748
Pull the upstream changes from diffusers' AttnProcessor2_0 into CustomAttnProcessor2_0. This fixes a bug in CustomAttnProcessor2_0 that was being triggered when peft was not installed. The bug was present in a block of code that was previously copied from diffusers. The bug seems to have been introduced during diffusers' migration to PEFT for their LoRA handling. The upstream bug was fixed in 531e719163
.
2024-04-09 08:12:12 -04:00
a78df8123f
Update the diffusion logic to use the new regional prompting feature.
2024-04-09 08:12:12 -04:00
7ca677578e
Create a UNetAttentionPatcher for patching UNet models with CustomAttnProcessor2_0 modules.
2024-04-09 08:12:12 -04:00
31c456c1e6
Update CustomAttention to support both IP-Adapters and regional prompting.
2024-04-09 08:12:12 -04:00
2ce79b61f5
Initialize a RegionalPromptAttnProcessor2_0 class by copying AttnProcessor2_0 from diffusers.
2024-04-09 08:12:12 -04:00
109e3f0e7f
Add RegionalPromptData class for managing prompt region masks.
2024-04-09 08:12:12 -04:00
d1e45585d0
Add TextConditioningRegions to the TextConditioningData data structure.
2024-04-09 08:12:12 -04:00
aba023e0c5
Improve documentation of conditioning_data.py.
2024-04-09 08:12:12 -04:00
e354c29b52
Rename ConditioningData -> TextConditioningData.
2024-04-09 08:12:12 -04:00
a7f363e654
Split ip_adapter_conditioning out from ConditioningData.
2024-04-09 08:12:12 -04:00
9b2162e564
Remove scheduler_args from ConditioningData structure.
2024-04-09 08:12:12 -04:00
b378cfcb46
cleanup: remove unused scripts, cruft
...
App runs & tests pass.
2024-03-20 15:05:25 +11:00
897fe497dc
fix(config): use new get_config across the app, use correct settings
2024-03-19 09:24:28 +11:00
145bb45858
Remove dead code related to an old symmetry feature.
2024-03-10 00:13:18 -06:00
cc45007dc4
Remove unused code for attention map saving.
2024-03-02 08:25:41 -05:00
73bec56c59
Delete unused functions from shared_invokeai_diffusion.py.
2024-03-02 08:25:41 -05:00
6935830f99
Remove unused constructor declared with typo in name: __int__.
2024-03-01 15:12:03 -05:00
7651eeea8d
Merge sequential conditioning and cac conditioning logic to eliminate a bunch of duplication.
2024-03-01 15:12:03 -05:00
9bc4e7a593
Remove use of **kwargs in do_unet_step(...), where full parameter list is known and supported.
2024-03-01 15:12:03 -05:00
ad96857e0f
Fix avoid storing extra conditioning info in two places.
2024-03-01 15:12:03 -05:00
dd9daf8efb
chore: ruff
2024-03-01 10:42:33 +11:00
05fb485d33
feat(nodes): move ConditioningFieldData
to conditioning_data.py
2024-03-01 10:42:33 +11:00
73a077956b
Why did my IDE change the comment?
2024-02-01 20:40:28 -05:00
5e1e50bd47
Fix hopefully last import
2024-02-01 20:40:28 -05:00
0beb08686c
Add CFG Rescale option for supporting zero-terminal SNR models ( #4335 )
...
* add support for CFG rescale
* fix typo
* move rescale position and tweak docs
* move input position
* implement suggestions from github and discord
* cleanup unused code
* add back dropped FieldDescription
* fix(ui): revert unrelated UI changes
* chore(nodes): bump denoise_latents version 1.4.0 -> 1.5.0
* feat(nodes): add cfg_rescale_multiplier to metadata node
* feat(ui): add cfg rescale multiplier to linear UI
- add param to state
- update graph builders
- add UI under advanced
- add metadata handling & recall
- regen types
* chore: black
* fix(backend): make `StableDiffusionGeneratorPipeline._rescale_cfg()` staticmethod
This doesn't need access to class.
* feat(backend): add docstring for `_rescale_cfg()` method
* feat(ui): update cfg rescale mult translation string
---------
Co-authored-by: psychedelicious <4822129+psychedelicious@users.noreply.github.com >
2023-11-30 20:55:20 +11:00
6494e8e551
chore: ruff format
2023-11-11 10:55:40 +11:00
513fceac82
chore: ruff check - fix pycodestyle
2023-11-11 10:55:33 +11:00
99a8ebe3a0
chore: ruff check - fix flake8-bugbear
2023-11-11 10:55:28 +11:00
67f2616d5a
Merge branch 'main' into revert-4923-revert-4914-feat/mix-cnet-t2iadapter
2023-11-06 07:34:51 -08:00
a078efc0f2
Merge branch 'main' into ryan/multi-image-ip
2023-10-18 08:59:12 -04:00
8afc47018b
Revert "Revert "Cleaning up (removing diagnostic prints)""
...
This reverts commit 6e697b7b6f
.
2023-10-17 11:59:19 -04:00
a97ec88e06
Revert "Revert "Changes to _apply_standard_conditioning_sequentially() and _apply_cross_attention_controlled_conditioning() to reflect changes to T2I-Adapter implementation to allow usage of T2I-Adapter and ControlNet at the same time.""
...
This reverts commit c04fb451ee
.
2023-10-17 11:59:19 -04:00
c04fb451ee
Revert "Changes to _apply_standard_conditioning_sequentially() and _apply_cross_attention_controlled_conditioning() to reflect changes to T2I-Adapter implementation to allow usage of T2I-Adapter and ControlNet at the same time."
...
This reverts commit 378689a519
.
2023-10-17 11:59:11 -04:00
6e697b7b6f
Revert "Cleaning up (removing diagnostic prints)"
...
This reverts commit 06f8a3276d
.
2023-10-17 11:59:11 -04:00
06f8a3276d
Cleaning up (removing diagnostic prints)
2023-10-17 19:42:06 +11:00
378689a519
Changes to _apply_standard_conditioning_sequentially() and _apply_cross_attention_controlled_conditioning() to reflect changes to T2I-Adapter implementation to allow usage of T2I-Adapter and ControlNet at the same time.
...
Also, the PREVIOUS commit (@8d3885d, which was already pushed to github repo) was wrongly commented, but too late to fix without a force push or other mucking that I'm reluctant to do. That commit is actually the one that has all the changes to diffusers_pipeline.py to use additional arg down_intrablock_additional_residuals (introduced in diffusers PR https://github.com/huggingface/diffusers/pull/5362 ) to detangle T2I-Adapter from ControlNet inputs to main UNet.
2023-10-17 19:42:06 +11:00