mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Merge branch 'feat/controlnet-control-modes' of https://github.com/invoke-ai/InvokeAI into feat/controlnet-control-modes
This commit is contained in:
commit
a8e0490133
@ -730,6 +730,14 @@ class StableDiffusionGeneratorPipeline(StableDiffusionPipeline):
|
||||
]
|
||||
mid_block_res_sample += mid_sample
|
||||
|
||||
# guess mode handling from diffusers controlnet pipeline:
|
||||
# if guess_mode and do_classifier_free_guidance:
|
||||
# # Inferred ControlNet only for the conditional batch.
|
||||
# # To apply the output of ControlNet to both the unconditional and conditional batches,
|
||||
# # add 0 to the unconditional batch to keep it unchanged.
|
||||
# down_block_res_samples = [torch.cat([torch.zeros_like(d), d]) for d in down_block_res_samples]
|
||||
# mid_block_res_sample = torch.cat([torch.zeros_like(mid_block_res_sample), mid_block_res_sample])
|
||||
|
||||
# predict the noise residual
|
||||
noise_pred = self.invokeai_diffuser.do_diffusion_step(
|
||||
x=unet_latent_input,
|
||||
|
Loading…
Reference in New Issue
Block a user