Visit ComfyUI Online for ready-to-use ComfyUI environment
Adjust pixel values of image to specified range for normalization, scaling, and processing tasks, with clamping option.
The RemapImageRange node is designed to adjust the pixel values of an image to a specified range. This is particularly useful when you need to normalize or scale image data for various processing tasks. By remapping the image values, you can ensure that the pixel intensities fall within a desired range, which can be crucial for tasks like image blending, thresholding, or preparing images for machine learning models. The node also offers an option to clamp the values, ensuring they stay within a specified range, thus preventing any outliers or extreme values that could affect subsequent processing steps.
This parameter accepts the input image that you want to remap. The image should be in a format compatible with the node, typically a tensor. The image's pixel values will be adjusted based on the specified minimum and maximum values.
This parameter sets the minimum value to which the image's pixel values will be remapped. The default value is 0.0, with a range from -10.0 to 1.0. Adjusting this value will shift the lower bound of the pixel intensity range.
This parameter sets the maximum value to which the image's pixel values will be remapped. The default value is 1.0, with a range from 0.0 to 10.0. Adjusting this value will shift the upper bound of the pixel intensity range.
This boolean parameter determines whether the remapped values should be clamped to stay within the range of 0.0 to 1.0. The default value is True. When enabled, any values outside this range will be clipped, ensuring that the pixel values do not exceed the specified bounds.
The output is the remapped image with pixel values adjusted to the specified range. If clamping is enabled, the values will be restricted to the range of 0.0 to 1.0. This ensures that the image is normalized and ready for further processing or analysis.
min
and max
parameters to normalize images to a specific range required by your application, such as preparing images for neural network input.clamp
option to prevent any pixel values from exceeding the desired range, which can be particularly useful when working with images that will be combined or compared with others.min
and max
values to see how they affect the contrast and brightness of the image, which can be useful for enhancing visual features.start_index
parameter is set to a value that is outside the valid range of the image batch.start_index
is within the range of the image batch. If you want to start from the last image, set start_index
to -1.num_frames
parameter or ensure that the start_index
and num_frames
combination does not exceed the total number of images in the batch.torch.float16
.torch.float32
, before passing it to the node.© Copyright 2024 RunComfy. All Rights Reserved.