Fix crash when hr is disabled

This commit is contained in:
InvincibleDude 2023-03-04 18:09:05 +00:00 committed by GitHub
parent e97b83bdbb
commit b9fdb9f701
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -670,6 +670,8 @@ def process_images_inner(p: StableDiffusionProcessing) -> Processed:
if type(p) == StableDiffusionProcessingTxt2Img:
if p.enable_hr:
samples_ddim = p.sample(conditioning=c, unconditional_conditioning=uc, hr_conditioning=hr_c, hr_unconditional_conditioning=hr_uc, seeds=seeds, subseeds=subseeds, subseed_strength=p.subseed_strength, prompts=prompts)
else:
samples_ddim = p.sample(conditioning=c, unconditional_conditioning=uc, seeds=seeds, subseeds=subseeds, subseed_strength=p.subseed_strength, prompts=prompts)
else:
samples_ddim = p.sample(conditioning=c, unconditional_conditioning=uc, seeds=seeds, subseeds=subseeds, subseed_strength=p.subseed_strength, prompts=prompts)