ltdrdata / ComfyUI-Impact-Pack

Custom nodes pack for ComfyUI This custom node helps to conveniently enhance images through Detector, Detailer, Upscaler, Pipe, and more.
GNU General Public License v3.0
1.44k stars 144 forks source link

ImpactIfNone logic does match document #662

Closed SongOnWater closed 3 days ago

SongOnWater commented 3 days ago

In the document https://www.runcomfy.com/comfyui-nodes/ComfyUI-Impact-Pack/ImpactIfNone,

the correct code seems should be : def doit(self, signal=None, any_input=None): if signal is None: return (any_input, False, ) else: return (signal, True, )

ltdrdata commented 3 days ago

That is not a official documentation. AFAIK, It is generated by LLM. I realized that I had forgotten to write the node description in the README page, so I updated it.

ImpactIfNone - Returns true if any_input is None, and returns false if it is not None.

In the impact pack, a signal is always passthru. It's not meant to handle semantic of any values, but rather it's a mechanism to ensure the execution order of nodes in the workflow.