Skip to content

Commit

Permalink
fix(api): support normal LoRA keys in SDXL LoRAs
Browse files Browse the repository at this point in the history
  • Loading branch information
ssube committed Nov 22, 2023
1 parent c4aa262 commit 60615e0
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions api/onnx_web/convert/diffusion/lora.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,15 @@ def fix_xl_names(keys: Dict[str, Any], nodes: List[NodeProto]):
block = "up_blocks"
elif root.startswith("text_model"):
block = "text_model"
elif root.startswith("down_blocks"):
fixed[fix_node_name(key)] = value
continue
elif root.startswith("mid_blocks"):
fixed[fix_node_name(key)] = value
continue
elif root.startswith("up_blocks"):
fixed[fix_node_name(key)] = value
continue
else:
logger.warning("unknown XL key name: %s", key)
fixed[key] = value
Expand Down

0 comments on commit 60615e0

Please sign in to comment.