Generated reference · ComfyUI workflow · Utility & post

Batch Image Resize

Resize multiple images to specified dimensions with various scaling options and quality settings

Utility & post5nodesGPU noneout image_batch~5sv1.0.0

On this page
5Graph nodes
5Node classes
14Inputs
0Models

Tags: utilitybatchresizescalebulkprocessing

Inputs (14)#

The typed parameter surface callers bind when they request this workflow. Enum options and numeric bounds are the values the workflow document declares.

input_imagesimage_batchrequired
Batch of images to resize
resize_modeenumdefault fit_within
How to resize the images
options: exact_dimensionsscale_percentagefit_withinfill_croplongest_edgeshortest_edge
target_widthintegerdefault 1920
Target width in pixels
target_heightintegerdefault 1080
Target height in pixels
scale_percentageintegerdefault 50min 1max 400
Scale percentage (for scale_percentage mode)
maintain_aspect_ratiobooleandefault true
Maintain original aspect ratio
upscale_methodenumdefault lanczos
Interpolation method for upscaling
options: lanczosbicubicbilinearnearest
downscale_methodenumdefault area
Interpolation method for downscaling
options: lanczosareabicubicbilinear
background_colorstringdefault #FFFFFF
Background color for padding (when fit_within)
crop_positionenumdefault center
Crop position (when fill_crop)
options: centertopbottomleftrighttop_lefttop_rightbottom_leftbottom_right
sharpen_after_resizebooleandefault false
Apply light sharpening after resize
output_formatenumdefault png
Output file format
options: pngjpgwebp
jpg_qualityintegerdefault 90min 50max 100
JPEG quality (if applicable)
webp_qualityintegerdefault 85min 50max 100
WebP quality (if applicable)

ComfyUI node graph (5)#

The executable ComfyUI prompt graph: 5 nodes across 5 distinct node classes, wired by 6 data dependencies. Nodes tinted green come from a custom node pack this workflow declares; the rest are ComfyUI core / baked-community classes.

flowchart TD n0["1: LoadImageBatch"] n1["2: BatchResizeCalculator"] n2["3: BatchImageResize"] n3["4: BatchSharpen"] n4["5: SaveImageBatch"] n0 -->|images| n1 n0 -->|images| n2 n1 -->|dimensions| n2 n2 -->|images| n3 n3 -->|images| n4 n0 -->|filenames| n4 classDef custom fill:#12b886,stroke:#0b6b4f,color:#04110c; class n0,n1,n2,n3,n4 custom;
Data-flow DAG — scroll to zoom, drag to pan.

Nodes (5)#

1LoadImageBatchcustom pack
images = {{input_images}} tmpl
outputs: IMAGE_BATCHFILENAMES
2BatchResizeCalculatorcustom pack
images = ◂ node 1 · out[0]mode = {{resize_mode}} tmpltarget_width = {{target_width}} tmpltarget_height = {{target_height}} tmplscale_percentage = {{scale_percentage}} tmplmaintain_aspect = {{maintain_aspect_ratio}} tmpl
outputs: DIMENSIONS_BATCH
3BatchImageResizecustom pack
images = ◂ node 1 · out[0]dimensions = ◂ node 2 · out[0]upscale_method = {{upscale_method}} tmpldownscale_method = {{downscale_method}} tmplmode = {{resize_mode}} tmplbackground_color = {{background_color}} tmplcrop_position = {{crop_position}} tmpl
outputs: IMAGE_BATCH
4BatchSharpencustom pack
images = ◂ node 3 · out[0]enabled = {{sharpen_after_resize}} tmplamount = 0.3radius = 1.0
outputs: IMAGE_BATCH
5SaveImageBatchcustom pack
images = ◂ node 4 · out[0]filenames = ◂ node 1 · out[1]format = {{output_format}} tmpljpg_quality = {{jpg_quality}} tmplwebp_quality = {{webp_quality}} tmplfilename_prefix = resized_

Parameter banks (2)#

The prompt / configuration lookup tables this workflow keys into from its inputs — the vocabulary that turns a style / palette / preset selection into graph parameters.

resize_mode_descriptions (6)#

exact_dimensions
Resize to exact dimensions, may distort if aspect ratios differ
scale_percentage
Scale by percentage, maintains aspect ratio
fit_within
Fit within dimensions, add padding if needed
fill_crop
Fill dimensions, crop excess
longest_edge
Set longest edge to target_width, scale proportionally
shortest_edge
Set shortest edge to target_height, scale proportionally

preset_configurations (4)#

web_optimized
{"resize_mode": "longest_edge", "target_width": 1200, "output_format": "webp", "webp_quality": 80, "description": "Optimized for web display"}
thumbnail
{"resize_mode": "fill_crop", "target_width": 300, "target_height": 300, "output_format": "jpg", "jpg_quality": 85, "description": "Square thumbnails"}
social_media
{"resize_mode": "fit_within", "target_width": 1080, "target_height": 1080, "output_format": "jpg", "jpg_quality": 90, "description": "Social media friendly"}
print_preview
{"resize_mode": "longest_edge", "target_width": 2400, "output_format": "png", "sharpen_after_resize": true, "description": "Print preview quality"}

Models & dependencies#

Custom node packs (5)#

The non-core ComfyUI node classes this graph requires; the RunPod worker image the workflow runs on must bake or install a pack that provides every one of them.

LoadImageBatchBatchResizeCalculatorBatchImageResizeBatchSharpenSaveImageBatch

Output contract#

What a successful run of this workflow returns.

type
image_batch
format
variable
description
Batch of resized images

Taxonomy & routing#

How the control plane classifies this workflow — from the committed workflow-taxonomy-registry.json. It drives the consistency / control surface the agentic director can exercise over the workflow.

assetFamily
mkt-localization-variant-pack
outputPackageProfile
marketing-campaign-profile
controlModalities
color-script-lockmodel-lockprompt-template-locksampler-scheduler-lockseed-lockstyle-lock
consistencyDimensions
color-script
notes
Auto-mapped from utility defaults