Save 4 hours! We auto-setup your workflow! Free!

Drop your workflow.json — we handle every dependency, custom node, and model. Just open the link and run.

Auto-Setup Workflow Json (Free) Now!
ComfyUI > Nodes > comfyui-obvpm > Lazy Switch (obvpm)

ComfyUI Node: Lazy Switch (obvpm)

Class Name

LazySwitch (obvpm)

Category
obvpm/switches
Author
chanon (Account age: 5883days)
Extension
comfyui-obvpm
Latest Updated
2026-09-17
Github Stars
0.04K

How to Install comfyui-obvpm

Install this extension via the ComfyUI Manager by searching for comfyui-obvpm
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter comfyui-obvpm in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Lazy Switch (obvpm) Description

Optimizes efficiency by executing selected branch of conditional operation, reducing unnecessary processing for AI artists.

LazySwitch (obvpm):

The LazySwitch node is designed to optimize computational efficiency by executing only the selected branch of a conditional operation, thereby reducing unnecessary processing. This node is particularly beneficial in scenarios where you have multiple potential execution paths but only one needs to be evaluated based on a given condition. By focusing on the selected branch, LazySwitch minimizes resource usage and enhances performance, especially in complex workflows where upstream processes can be computationally expensive. This approach ensures that only the necessary computations are performed, making it an ideal choice for AI artists looking to streamline their workflows without compromising on functionality.

LazySwitch (obvpm) Input Parameters:

switch

The switch parameter is a boolean input that determines which branch of the node will be executed. If set to true, the node will execute the on_true branch; if set to false, it will execute the on_false branch. This parameter is crucial as it directly influences the node's execution path, allowing you to control the flow of your workflow based on dynamic conditions. There are no minimum or maximum values for this parameter as it is a simple true or false condition.

on_false

The on_false parameter is an integer input that represents the value or operation to be executed when the switch parameter is set to false. This input is lazy, meaning it will only be evaluated if the switch condition is false, thereby saving computational resources. The default behavior is to not execute this branch unless specified by the switch condition. This parameter allows you to define alternative operations or values that should be used when the primary condition is not met.

on_true

The on_true parameter is an integer input that represents the value or operation to be executed when the switch parameter is set to true. Similar to on_false, this input is lazy and will only be evaluated if the switch condition is true. This ensures that only the necessary computations are performed, optimizing the workflow's efficiency. This parameter is essential for defining the primary operation or value that should be used when the condition is met.

LazySwitch (obvpm) Output Parameters:

INT

The output of the LazySwitch node is an integer value, which corresponds to the result of the executed branch based on the switch condition. If the switch is true, the output will be the value from the on_true branch; if false, it will be from the on_false branch. This output is crucial as it provides the result of the conditional operation, allowing subsequent nodes in the workflow to utilize this value for further processing or decision-making.

LazySwitch (obvpm) Usage Tips:

  • Use the LazySwitch node to optimize workflows by ensuring only necessary computations are performed, which is particularly useful in complex or resource-intensive processes.
  • When setting up the node, clearly define the operations or values for both on_true and on_false branches to ensure that the workflow behaves as expected under different conditions.

LazySwitch (obvpm) Common Errors and Solutions:

Missing input for selected branch

  • Explanation: This error occurs when the switch condition is set to true or false, but the corresponding on_true or on_false input is not provided.
  • Solution: Ensure that both on_true and on_false inputs are properly connected and defined to avoid missing input errors.

Invalid switch value

  • Explanation: This error arises when the switch parameter receives a value that is not a boolean, causing the node to malfunction.
  • Solution: Verify that the switch parameter is correctly set to either true or false to ensure proper node execution.

Lazy Switch (obvpm) Related Nodes

Go back to the extension to check out more related nodes.
comfyui-obvpm
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

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.

Lazy Switch (obvpm)