summaryrefslogtreecommitdiffstats
path: root/training/strategy
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2023-04-09 16:21:52 +0200
committerVolpeon <git@volpeon.ink>2023-04-09 16:21:52 +0200
commit776213e99da4ec389575e797d93de8d8960fa010 (patch)
treea21a76e32dbacb707c3d251c56e92d618d5e921b /training/strategy
parentFix (diff)
downloadtextual-inversion-diff-776213e99da4ec389575e797d93de8d8960fa010.tar.gz
textual-inversion-diff-776213e99da4ec389575e797d93de8d8960fa010.tar.bz2
textual-inversion-diff-776213e99da4ec389575e797d93de8d8960fa010.zip
Update
Diffstat (limited to 'training/strategy')
-rw-r--r--training/strategy/ti.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/training/strategy/ti.py b/training/strategy/ti.py
index 289d6bd..9cdc1bb 100644
--- a/training/strategy/ti.py
+++ b/training/strategy/ti.py
@@ -119,7 +119,7 @@ def textual_inversion_strategy_callbacks(
119 ema_embeddings.step(text_encoder.text_model.embeddings.token_override_embedding.parameters()) 119 ema_embeddings.step(text_encoder.text_model.embeddings.token_override_embedding.parameters())
120 120
121 if use_emb_decay and w is not None: 121 if use_emb_decay and w is not None:
122 lr = lrs["emb"] or lrs["0"] 122 lr = lrs["emb"] if "emb" in lrs else lrs["0"]
123 lambda_ = emb_decay * lr 123 lambda_ = emb_decay * lr
124 124
125 if lambda_ != 0: 125 if lambda_ != 0: