mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-01-11 02:15:17 +00:00
Update nodes_differential_diffusion.py
This commit is contained in:
parent
ce31337813
commit
1a864435f6
@ -43,9 +43,11 @@ class DifferentialDiffusion():
|
|||||||
binary_mask = (denoise_mask >= threshold).to(denoise_mask.dtype)
|
binary_mask = (denoise_mask >= threshold).to(denoise_mask.dtype)
|
||||||
|
|
||||||
# Blend binary mask with the original denoise_mask using strength
|
# Blend binary mask with the original denoise_mask using strength
|
||||||
blended_mask = strength * binary_mask + (1 - strength) * denoise_mask
|
if strength and strength < 1:
|
||||||
|
blended_mask = strength * binary_mask + (1 - strength) * denoise_mask
|
||||||
return blended_mask
|
return blended_mask
|
||||||
|
else:
|
||||||
|
return binary_mask
|
||||||
|
|
||||||
|
|
||||||
NODE_CLASS_MAPPINGS = {
|
NODE_CLASS_MAPPINGS = {
|
||||||
|
Loading…
Reference in New Issue
Block a user