Video Helper Suite πŸŽ₯πŸ…₯πŸ…—πŸ…’/imagegenerated

Merge Images πŸŽ₯πŸ…₯πŸ…—πŸ…’(MergeImages)

In terms of technical implementation, this node first checks whether the dimensions of the two sets of input images are consistent.

Merge Images

images_A
images_B
IMAGE
count
merge_strategy
COMBO
scale_method
COMBO
crop
COMBO
VideoHelperSuite

The Merge Images πŸŽ₯πŸ…₯πŸ…—πŸ…’ node, in its technical implementation, first checks whether the dimensions of the two input image sets are consistent.

The Merge Images node is a tool for image processing. Its core function is to merge two sets of input images (images_A and images_B) into a single image batch. It intelligently handles images of different sizes, ensuring they can be seamlessly combined to provide a unified data source for subsequent image processing steps.

Node Functionality

In its technical implementation, this node first checks whether the dimensions of the two input image sets are consistent. If the sizes differ, the node decides which set of images to use as the reference for scaling based on the user-selected "merge strategy," and uses the specified "scale method" and "crop method" to adjust the size of the other image set. After unifying the dimensions, the node concatenates the two image sets along the batch dimension, ultimately outputting a merged image tensor and the total count of merged images.

Node Parameter Description - Merge Images πŸŽ₯πŸ…₯πŸ…—πŸ…’

Inputs

Parameter NameData TypeRequiredDefault ValueRange/OptionsDescription
images_AIMAGEYes--images_A (Input Parameter): The first batch of images to be merged.
images_BIMAGEYes--images_B (Input Parameter): The second batch of images to be merged.
merge_strategyMERGESTRATEGIESYes--Match B group, Match smaller size, Match larger size.
scale_methodSCALEMETHODSYes--Bicubic, etc.
cropCROPMETHODSYes--Disabled, etc.

Outputs

Parameter NameData TypeDescription
IMAGEIMAGEIMAGE (Output Parameter): The merged, unified image batch.
countINTcount (Output Parameter): The total number of images contained in the merged batch.

Usage Scenarios

This node is highly useful in practical workflows. For example, when you need to compare, blend, or feed two sets of image results generated using different models or parameters as a single batch into the next node (such as an upscaler or animation generator), you can use the Merge Images node. It ensures data format consistency and simplifies the construction of complex pipelines.

Notes

It is important to note that this node only performs image concatenation and does not involve pixel-level fusion (such as alpha blending). The order of images in the merged batch is: all images from images_A first, followed by all images from images_B.

The Merge Images πŸŽ₯πŸ…₯πŸ…—πŸ…’ node is from the ComfyUI-VideoHelperSuite node package.

Comments

Sign in with GitHub to join the discussion.

Loading comments…