mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-11 10:25:16 +00:00
Del the right object when applying lora.
This commit is contained in:
parent
85a8900a14
commit
12a6e93171
@ -353,7 +353,7 @@ class ModelPatcher:
|
|||||||
temp_weight = weight.to(torch.float32, copy=True)
|
temp_weight = weight.to(torch.float32, copy=True)
|
||||||
out_weight = self.calculate_weight(self.patches[key], temp_weight, key).to(weight.dtype)
|
out_weight = self.calculate_weight(self.patches[key], temp_weight, key).to(weight.dtype)
|
||||||
set_attr(self.model, key, out_weight)
|
set_attr(self.model, key, out_weight)
|
||||||
del temp_weight
|
del weight
|
||||||
return self.model
|
return self.model
|
||||||
|
|
||||||
def calculate_weight(self, patches, weight, key):
|
def calculate_weight(self, patches, weight, key):
|
||||||
|
Loading…
Reference in New Issue
Block a user