CFG and Distilled CFG for hiresfix (#1810)

This commit is contained in:
DenOfEquity
2024-09-13 15:01:40 +01:00
committed by GitHub
parent e55cde9b33
commit cb412b290b
5 changed files with 43 additions and 16 deletions

View File

@@ -184,6 +184,9 @@ class CFGDenoiser(torch.nn.Module):
cfg_denoiser_callback(denoiser_params)
# NGMS
if self.p.is_hr_pass == True:
cond_scale = self.p.hr_cfg
if shared.opts.skip_early_cond > 0 and self.step / self.total_steps <= shared.opts.skip_early_cond:
cond_scale = 1.0
self.p.extra_generation_params["Skip Early CFG"] = shared.opts.skip_early_cond