Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
laksjdjf authored Mar 21, 2024
1 parent 237cb3b commit a7e764d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions networks/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ def __init__(
if state_dict or text_module_args is not None:
self.text_encoder_modules = []
if text_model.sdxl:
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER_1, text_model, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te1_keys)
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER_2, text_model, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te2_keys)
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER_1, text_model.text_encoder, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te1_keys)
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER_2, text_model.text_encoder_2, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te2_keys)
else:
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER, text_model, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te_keys)
self.text_encoder_modules += self.create_modules(LORA_PREFIX_TEXT_ENCODER, text_model.text_encoder, TEXT_ENCODER_TARGET_REPLACE_MODULE, state_dict, text_module_args, None, te_keys)
else:
self.text_encoder_modules = []

Expand Down Expand Up @@ -172,4 +172,4 @@ def set_temporary_multiplier(self, multiplier):
lora.multiplier = multiplier
yield
for lora in self.text_encoder_modules + self.unet_modules:
lora.multiplier = 1.0
lora.multiplier = 1.0

0 comments on commit a7e764d

Please sign in to comment.