ComfyUI > Nodes > Bjornulf_custom_nodes > ♻ Loop (Integer)

ComfyUI Node: ♻ Loop (Integer)

Class Name

Bjornulf_LoopInteger

Category
Bjornulf
Author
justUmen (Account age: 3046days)
Extension
Bjornulf_custom_nodes
Latest Updated
2025-02-28
Github Stars
0.2K

How to Install Bjornulf_custom_nodes

Install this extension via the ComfyUI Manager by searching for Bjornulf_custom_nodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Bjornulf_custom_nodes 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

♻ Loop (Integer) Description

Generate integer sequences within specified range for controlled iteration in workflows.

♻ Loop (Integer):

The Bjornulf_LoopInteger node is designed to generate a sequence of integer values within a specified range, providing a simple yet powerful tool for iterating over numbers in a controlled manner. This node is particularly useful for tasks that require repetitive operations over a series of integer values, such as batch processing or iterative calculations. By defining a start point, an endpoint, and a step size, you can create a list of integers that can be used in various creative and computational workflows. The node's primary function is to automate the generation of these sequences, allowing you to focus on the creative aspects of your project without worrying about the underlying numerical logic.

♻ Loop (Integer) Input Parameters:

from_this

The from_this parameter specifies the starting point of the integer sequence. It determines the initial value from which the sequence will begin. The minimum value for this parameter is 0, the maximum is 1000, and the default is set to 0. Adjusting this parameter allows you to control where the sequence starts, which can be crucial for aligning the sequence with your specific needs.

to_that

The to_that parameter defines the endpoint of the integer sequence. It sets the maximum value that the sequence can reach. The minimum value for this parameter is 0, the maximum is 1000, and the default is set to 10. This parameter is essential for determining the range of the sequence, ensuring that it does not exceed the desired limit.

jump

The jump parameter determines the step size between consecutive integers in the sequence. It controls how much the sequence increments with each step. The minimum value for this parameter is 0, the maximum is 1000, and the default is set to 1. By adjusting this parameter, you can control the granularity of the sequence, allowing for both fine and coarse iterations.

♻ Loop (Integer) Output Parameters:

INT

The output of the Bjornulf_LoopInteger node is a list of integers, represented by the INT type. This list contains the sequence of integers generated based on the input parameters. The output is crucial for any process that requires a series of numbers, as it provides the necessary data to drive iterative operations or batch processes. The list format allows for easy integration with other nodes or systems that can utilize integer sequences.

♻ Loop (Integer) Usage Tips:

  • To create a sequence that includes every integer from 0 to 10, set from_this to 0, to_that to 10, and jump to 1. - For larger sequences, ensure that the jump value is appropriately set to avoid generating excessively large lists that may impact performance.
  • Use the node in conjunction with other nodes that can process lists to maximize its utility in batch operations.

♻ Loop (Integer) Common Errors and Solutions:

Counter has reached its limit of <to_that>, Reset Counter to continue.

  • Explanation: This error occurs when the sequence has reached the specified endpoint, and no further increments are possible.
  • Solution: Adjust the to_that parameter to a higher value if you need a longer sequence, or reset the starting point to begin a new sequence.

Invalid jump value

  • Explanation: This error may occur if the jump parameter is set to 0, which would result in an infinite loop.
  • Solution: Ensure that the jump parameter is set to a positive integer to allow the sequence to progress correctly.

♻ Loop (Integer) Related Nodes

Go back to the extension to check out more related nodes.
Bjornulf_custom_nodes
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 Playground, enabling artists to harness the latest AI tools to create incredible art.