ComfyUI > Nodes > Derfuu_ComfyUI_ModdedNodes > Latent Scale to side

ComfyUI Node: Latent Scale to side

Class Name

DF_Latent_Scale_to_side

Category
Derfuu_Nodes/Modded nodes/Latent
Author
Derfuu (Account age: 1829days)
Extension
Derfuu_ComfyUI_ModdedNodes
Latest Updated
2024-06-22
Github Stars
0.33K

How to Install Derfuu_ComfyUI_ModdedNodes

Install this extension via the ComfyUI Manager by searching for Derfuu_ComfyUI_ModdedNodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Derfuu_ComfyUI_ModdedNodes 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
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Latent Scale to side Description

Upscale latent images based on specified side length and scaling method, maintaining aspect ratio and original proportions.

Latent Scale to side:

The DF_Latent_Scale_to_side node is designed to upscale latent images by adjusting their dimensions based on a specified side length and scaling method. This node is particularly useful for AI artists who need to resize latent images while maintaining the aspect ratio, ensuring that the upscaled images retain their original proportions. By allowing you to choose whether to scale based on the longest or shortest side, or explicitly by width or height, this node provides flexibility in how the latent images are resized. Additionally, it supports various scaling methods and cropping options to fine-tune the upscaling process, making it a versatile tool for enhancing the resolution of latent images in your AI art projects.

Latent Scale to side Input Parameters:

latent

This parameter represents the latent image that you want to upscale. It is the core input for the node, containing the image data that will be processed.

side_length

This integer parameter specifies the target length for the chosen side (width or height) of the latent image. The node will scale the image such that the specified side matches this length. The default value is 512.

side

This parameter allows you to choose which side of the image to scale. Options include "Longest", "Shortest", "Width", and "Height". Depending on your choice, the node will adjust the dimensions of the latent image accordingly.

scale_method

This parameter determines the method used for scaling the image. Available options are "nearest-exact", "bilinear", "bicubic", "bislerp", "area", and "lanczos". Each method offers different trade-offs between speed and quality, allowing you to select the most appropriate one for your needs.

crop

This parameter specifies the cropping method to be used during the upscaling process. Options include "disabled" and "center". Choosing "disabled" will not apply any cropping, while "center" will crop the image from the center if necessary to maintain the aspect ratio.

Latent Scale to side Output Parameters:

LATENT

The output is a latent image that has been upscaled according to the specified parameters. This upscaled latent image retains the original proportions and is ready for further processing or use in your AI art projects.

Latent Scale to side Usage Tips:

  • To maintain the aspect ratio of your latent image while scaling, choose the "Longest" or "Shortest" option for the side parameter.
  • Experiment with different scale_method options to find the best balance between processing speed and image quality for your specific use case.
  • Use the crop parameter set to "center" if you need to ensure that the important parts of the image remain in focus after upscaling.

Latent Scale to side Common Errors and Solutions:

Error: "Invalid side length"

  • Explanation: The side_length parameter must be a positive integer.
  • Solution: Ensure that you provide a valid positive integer for the side_length parameter.

Error: "Unsupported scale method"

  • Explanation: The scale_method parameter must be one of the predefined options.
  • Solution: Verify that you are using one of the supported scale methods: "nearest-exact", "bilinear", "bicubic", "bislerp", "area", or "lanczos".

Error: "Invalid crop method"

  • Explanation: The crop parameter must be either "disabled" or "center".
  • Solution: Check that you have selected a valid cropping method from the available options.

Latent Scale to side Related Nodes

Go back to the extension to check out more related nodes.
Derfuu_ComfyUI_ModdedNodes
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.