Skip to content

Commit

Permalink
Simpletrainer lycoris format.
Browse files Browse the repository at this point in the history
  • Loading branch information
comfyanonymous committed Aug 20, 2024
1 parent 9953f22 commit ea63b1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions comfy/lora.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ def model_lora_keys_unet(model, key_map={}):
for k in diffusers_keys:
if k.endswith(".weight"):
to = diffusers_keys[k]
key_lora = "transformer.{}".format(k[:-len(".weight")]) #simpletrainer and probably regular diffusers flux lora format
key_map[key_lora] = to
key_map["transformer.{}".format(k[:-len(".weight")])] = to #simpletrainer and probably regular diffusers flux lora format
key_map["lycoris_{}".format(k[:-len(".weight")].replace(".", "_"))] = to #simpletrainer lycoris

return key_map

0 comments on commit ea63b1c

Please sign in to comment.