ComfyUI > Nodes > ComfyUI-JDCN > LogicUtil_Yieldable (Sequential) Iterator Int

ComfyUI Node: LogicUtil_Yieldable (Sequential) Iterator Int

Class Name

LogicUtil_YieldableIteratorInt

Category
LogicUtil
Author
daxcay (Account age: 93days)
Extension
ComfyUI-JDCN
Latest Updated
2024-06-13
Github Stars
0.06K

How to Install ComfyUI-JDCN

Install this extension via the ComfyUI Manager by searching for ComfyUI-JDCN
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-JDCN 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
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

LogicUtil_Yieldable (Sequential) Iterator Int Description

Generates integer sequences with reset capability for controlled iteration and value generation.

LogicUtil_Yieldable (Sequential) Iterator Int:

The LogicUtil_YieldableIteratorInt node is designed to generate a sequence of integers based on specified start, end, and step values. This node is particularly useful when you need to iterate over a range of numbers in a controlled manner, such as for creating loops or generating a series of values for further processing. One of its key features is the ability to reset the sequence, allowing you to start the iteration from the beginning whenever needed. This can be especially beneficial in scenarios where you need to repeat a sequence multiple times or ensure that the sequence starts fresh under certain conditions.

LogicUtil_Yieldable (Sequential) Iterator Int Input Parameters:

start

The start parameter defines the initial value of the sequence. It determines where the iteration begins. The default value is 0, with a minimum value of 0 and a maximum value of 9999999999. Adjusting this parameter allows you to control the starting point of your sequence.

end

The end parameter specifies the value at which the sequence will stop. The iteration will continue up to, but not including, this value. The default value is 10, with a minimum value of 0 and a maximum value of 9999999999. This parameter is crucial for defining the range of your sequence.

step

The step parameter indicates the increment between each value in the sequence. It determines how much the sequence value increases with each iteration. The default value is 1, with a minimum value of 0 and a maximum value of 9999999999. By adjusting this parameter, you can control the spacing between the values in your sequence.

reset

The reset parameter is a boolean flag (0 or 1) that determines whether the sequence should start over from the beginning. If set to 1 (True), the sequence will reset to the start value. The default value is 0 (False). This parameter is useful for scenarios where you need to reinitialize the sequence.

LogicUtil_Yieldable (Sequential) Iterator Int Output Parameters:

INT

The output of the LogicUtil_YieldableIteratorInt node is a single integer value from the sequence. This value is generated based on the current state of the iterator and the specified start, end, and step parameters. The output is crucial for any subsequent operations that require a sequential integer value.

LogicUtil_Yieldable (Sequential) Iterator Int Usage Tips:

  • To create a simple loop that iterates from 0 to 9, set start to 0, end to 10, and step to 1. - Use the reset parameter to restart the sequence from the beginning whenever a specific condition is met, ensuring consistent iteration behavior.

LogicUtil_Yieldable (Sequential) Iterator Int Common Errors and Solutions:

"StopIteration"

  • Explanation: This error occurs when the iterator reaches the end of the sequence and there are no more values to yield.
  • Solution: The node automatically handles this by resetting the iterator. Ensure that your end value is greater than your start value to avoid infinite loops.

"Invalid step value"

  • Explanation: This error occurs if the step value is set to 0, which would result in an infinite loop.
  • Solution: Ensure that the step value is greater than 0 to allow the sequence to progress correctly.

LogicUtil_Yieldable (Sequential) Iterator Int Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-JDCN
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.