A custom node for ComfyUI, LoadLoopImagesFromDir facilitates the sequential loading of images from a specified directory, automatically cycling back to the first image upon reaching the end. This tool is particularly useful for workflows that require repetitive access to a set of images without manual intervention.
- Loads images one at a time, advancing automatically on each call.
- Supports various image formats including .jpg, .jpeg, .png, and .webp, and can extract masks from images with alpha channels.
- Outputs a tensor representation of the image, a corresponding mask, and the full file path for further processing.
Context
LoadLoopImagesFromDir is a specialized node designed for use within the ComfyUI framework, enabling users to efficiently manage and utilize a series of images stored in a directory. Its primary function is to streamline the process of loading images sequentially, which is beneficial for tasks like animation, testing, or batch processing.
Key Features & Benefits
This node allows for the automatic loading of images, which eliminates the need for manual selection and reduces the risk of errors during repetitive tasks. By looping back to the first image, it ensures a continuous flow of data, making it ideal for applications that require cycling through a set of images without interruption.
Advanced Functionalities
The node can handle images with alpha channels, allowing it to extract and return masks alongside the images. This feature is particularly useful for projects that require transparency or specific masking effects, enhancing the versatility of the tool.
Practical Benefits
Using LoadLoopImagesFromDir significantly enhances workflow efficiency by automating image loading processes. It provides greater control over image sequences and ensures consistency in the data being processed, ultimately improving the quality of outputs in ComfyUI.
Credits/Acknowledgments
The node is developed under the GPL-3.0 license, encouraging contributions from the community. Users are welcome to report issues or submit pull requests on the GitHub repository to enhance the tool's functionality and address any bugs.