Visit ComfyUI Online for ready-to-use ComfyUI environment
Facilitates conditional execution in node-based workflows, directing data flow based on boolean conditions.
The CRZ Execute Switch node is designed to facilitate conditional execution within a node-based workflow, allowing you to direct the flow of data based on a boolean condition. This node is particularly useful when you need to decide between two paths of execution, effectively acting as a gatekeeper that routes input data to one of two outputs depending on the specified condition. By leveraging this node, you can streamline your workflow, ensuring that only the relevant branch of execution is processed, which can enhance efficiency and reduce unnecessary computations. The node employs an ExecutionBlocker to prevent the execution of the inactive branch, ensuring that resources are not wasted on processing paths that are not needed.
The input parameter accepts any type of data and serves as the primary data input for the node. This parameter is routed to one of the two outputs based on the boolean condition specified by the bool parameter. There are no specific minimum or maximum values for this parameter, as it is designed to handle any data type. The default value is None, indicating that no data is provided initially.
The bool parameter is a boolean input that determines the routing of the input data. When set to True, the input data is directed to the true output, while the false output is blocked. Conversely, when set to False, the input data is directed to the false output, and the true output is blocked. This parameter does not have a range of values, as it is strictly a boolean type. The default value is False, meaning that, by default, the input data will be routed to the false output.
The true output parameter receives the input data when the bool parameter is set to True. This output is significant as it represents the active path of execution when the condition is met. If the bool parameter is False, this output is blocked using an ExecutionBlocker, preventing any data from being processed through this path.
The false output parameter receives the input data when the bool parameter is set to False. This output is crucial for scenarios where the condition is not met, and the alternative path of execution is required. If the bool parameter is True, this output is blocked using an ExecutionBlocker, ensuring that no data is processed through this path.
CRZExecuteSwitch node to manage complex workflows where conditional logic is required, allowing you to efficiently direct data flow based on specific conditions.bool parameter is correctly set to reflect the desired condition for routing the input data, as this will determine which output path is activated.ExecutionBlocker module is not available in your environment, which is used to block the inactive output path.comfy_execution package is correctly installed and accessible in your environment. If the package is unavailable, consider updating your environment or using the fallback mechanism provided by the node, which does not rely on ExecutionBlocker.input parameter is not None unless intentionally left as such.RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.