Fixed error with wan models when caching text embeddings
This commit is contained in:
@@ -654,10 +654,10 @@ class Wan21(BaseModel):
|
|||||||
return latents.to(device, dtype=dtype)
|
return latents.to(device, dtype=dtype)
|
||||||
|
|
||||||
def get_model_has_grad(self):
|
def get_model_has_grad(self):
|
||||||
return self.model.proj_out.weight.requires_grad
|
return False
|
||||||
|
|
||||||
def get_te_has_grad(self):
|
def get_te_has_grad(self):
|
||||||
return self.text_encoder.encoder.block[0].layer[0].SelfAttention.q.weight.requires_grad
|
return False
|
||||||
|
|
||||||
def save_model(self, output_path, meta, save_dtype):
|
def save_model(self, output_path, meta, save_dtype):
|
||||||
# only save the unet
|
# only save the unet
|
||||||
|
|||||||
Reference in New Issue
Block a user