mirror of
https://github.com/ostris/ai-toolkit.git
synced 2026-03-05 10:39:49 +00:00
Convert wan lora weights on save to be something comfy can handle
This commit is contained in:
@@ -3061,3 +3061,11 @@ class StableDiffusion:
|
||||
encoder.to(*args, **kwargs)
|
||||
else:
|
||||
self.text_encoder.to(*args, **kwargs)
|
||||
|
||||
def convert_lora_weights_before_save(self, state_dict):
|
||||
# can be overridden in child classes to convert weights before saving
|
||||
return state_dict
|
||||
|
||||
def convert_lora_weights_before_load(self, state_dict):
|
||||
# can be overridden in child classes to convert weights before loading
|
||||
return state_dict
|
||||
|
||||
Reference in New Issue
Block a user