Skip to content

Commit d7385a6

Browse files
author
jiashunran
committedFeb 9, 2023
fix "local variable 'unet_path' referenced before assignment" in patch_pipe
1 parent 848db91 commit d7385a6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed
 

‎lora_diffusion/lora.py

+2
Original file line numberDiff line numberDiff line change
@@ -974,6 +974,8 @@ def patch_pipe(
974974
unet_path = maybe_unet_path[:-6] + ".pt"
975975
elif maybe_unet_path.endswith(".text_encoder.pt"):
976976
unet_path = maybe_unet_path[:-16] + ".pt"
977+
else:
978+
unet_path = maybe_unet_path
977979

978980
ti_path = _ti_lora_path(unet_path)
979981
text_path = _text_lora_path(unet_path)

0 commit comments

Comments
 (0)