mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-07-07 07:01:46 +08:00
Merge 1af8dcacac into b08debceca
This commit is contained in:
commit
84d1ad8583
@ -73,7 +73,7 @@ class APG(io.ComfyNode):
|
||||
guidance = cond - uncond
|
||||
|
||||
if momentum != 0:
|
||||
if not torch.is_tensor(running_avg):
|
||||
if not torch.is_tensor(running_avg) or (running_avg.shape != guidance.shape):
|
||||
running_avg = guidance
|
||||
else:
|
||||
running_avg = momentum * running_avg + guidance
|
||||
|
||||
Loading…
Reference in New Issue
Block a user