better diffusers embedding handling

This commit is contained in:
Vladimir Mandic
2023-09-26 12:04:26 -04:00
parent e661d7bce7
commit 14aec521ed
5 changed files with 46 additions and 23 deletions
+2 -2
View File
@@ -177,8 +177,8 @@ def process_diffusers(p: StableDiffusionProcessing, seeds, prompts, negative_pro
return prompts, negative_prompts, prompts_2, negative_prompts_2
def set_pipeline_args(model, prompts: list, negative_prompts: list, prompts_2: typing.Optional[list]=None, negative_prompts_2: typing.Optional[list]=None, desc:str='', **kwargs):
if hasattr(model, 'embedding_db'):
del model.embedding_db
# if hasattr(model, 'embedding_db'):
# del model.embedding_db
try:
is_refiner = model.text_encoder.__class__.__name__ != 'CLIPTextModel'
except Exception: