mirror of
https://github.com/lllyasviel/stable-diffusion-webui-forge.git
synced 2026-04-26 09:18:59 +00:00
Backend: Allow control signal to be none for advanced weighting
This commit is contained in:
@@ -64,6 +64,10 @@ def compute_controlnet_weighting(control, cnet):
|
|||||||
for k, v in control.items():
|
for k, v in control.items():
|
||||||
for i in range(len(v)):
|
for i in range(len(v)):
|
||||||
control_signal = control[k][i]
|
control_signal = control[k][i]
|
||||||
|
|
||||||
|
if not isinstance(control_signal, torch.Tensor):
|
||||||
|
continue
|
||||||
|
|
||||||
B, C, H, W = control_signal.shape
|
B, C, H, W = control_signal.shape
|
||||||
|
|
||||||
positive_weight = 1.0
|
positive_weight = 1.0
|
||||||
|
|||||||
Reference in New Issue
Block a user