ComfyUI > Nodes > WhiteRabbit > 🐇 Batch Resize w/ Lanczos

ComfyUI Node: 🐇 Batch Resize w/ Lanczos

Class Name

BatchResizeWithLanczos

Category
image/resize
Author
Artificial-Sweetener (Account age: 367days)
Extension
WhiteRabbit
Latest Updated
2025-11-17
Github Stars
0.04K

How to Install WhiteRabbit

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

🐇 Batch Resize w/ Lanczos Description

Efficiently resize image batches with Lanczos resampling for high-quality results and memory optimization.

🐇 Batch Resize w/ Lanczos:

Batch Resize with Lanczos is a node designed to efficiently resize batches of images using the Lanczos resampling method, which is known for its ability to maintain image quality during scaling operations. This node is particularly beneficial for processing large batches of images, as it includes controls to manage memory usage and optimize processing speed. By leveraging the Lanczos algorithm, it provides high-quality image resizing with minimal artifacts, making it ideal for applications where image clarity is paramount. The node offers several adjustable parameters that allow you to fine-tune the resizing process, ensuring that the output meets your specific needs while avoiding common pitfalls such as out-of-memory errors.

🐇 Batch Resize w/ Lanczos Input Parameters:

max_batch_size

This parameter controls the maximum number of images processed in a single batch. Setting this to a value greater than 0 allows the node to process images in chunks, which helps manage VRAM usage and prevents slowdowns due to fallback mechanisms. The default value is 0, which means the entire batch is processed at once. The minimum value is 0, and the maximum is 4096.

sinc_window

The sinc_window parameter determines the size of the Lanczos window used during the resizing process. A larger window size results in sharper images but may introduce more ringing artifacts. The default value is 3, with a minimum of 1 and a maximum of 8.

precision

This parameter specifies the data type used for resampling computations. Options include "fp32" (single precision), "fp16" (half precision), and "bf16" (bfloat16). Using lower precision can speed up processing on compatible GPUs, but it may affect image quality. The default setting is "fp32", which provides the safest quality.

🐇 Batch Resize w/ Lanczos Output Parameters:

images_out

This output contains the resized images, processed according to the specified parameters. The images are returned in a format that maintains their original quality as much as possible, thanks to the Lanczos resampling method.

out_w

This parameter represents the width of the output images after resizing. It reflects the target width specified during the resizing process.

out_h

This parameter represents the height of the output images after resizing. It reflects the target height specified during the resizing process.

mask_out

The mask_out output provides a mask that corresponds to the resized images. This mask can be used for further processing or analysis, ensuring that any transformations applied to the images are accurately reflected in the mask.

🐇 Batch Resize w/ Lanczos Usage Tips:

  • To optimize performance and prevent memory issues, adjust the max_batch_size parameter according to your system's VRAM capacity.
  • Experiment with the sinc_window size to find a balance between sharpness and ringing artifacts that suits your project needs.
  • Consider using precision settings like "fp16" or "bf16" if you are working on a GPU that supports these formats, as they can significantly speed up processing times.

🐇 Batch Resize w/ Lanczos Common Errors and Solutions:

Out of Memory Error

  • Explanation: This error occurs when the node attempts to process more data than the available VRAM can handle.
  • Solution: Reduce the max_batch_size to process smaller chunks of images, or lower the tile_size to decrease memory usage.

Image Quality Degradation

  • Explanation: Lower precision settings or inappropriate sinc_window sizes can lead to noticeable quality loss in the resized images.
  • Solution: Use "fp32" for precision to ensure the highest quality, and adjust the sinc_window to a value that minimizes artifacts while maintaining sharpness.

🐇 Batch Resize w/ Lanczos Related Nodes

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