Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,11 @@ def extract_lora(self, base_model, base_model_clip, other_model, other_model_cli
other_data = other_model.model_state_dict()
key_count = len(base_data.keys())
if save_clip:
key_count += len(base_model_clip.get_sd().keys())
if base_model_clip is None or other_model_clip is None:
print("Warning: save_clip is True but CLIP model(s) are unavailable (model may not have embedded CLIP, e.g. Flux), skipping CLIP extraction")
save_clip = False
else:
key_count += len(base_model_clip.get_sd().keys())
pbar = comfy.utils.ProgressBar(key_count)
class Helper:
steps = 0
Expand Down
Loading