ComfyUI > Nodes > ComfyUI-Apt_Preset > sum_latent

ComfyUI Node: sum_latent

Class Name

sum_latent

Category
Apt_Preset/chx_tool
Author
cardenluo (Account age: 1062days)
Extension
ComfyUI-Apt_Preset
Latest Updated
2026-04-04
Github Stars
0.28K

How to Install ComfyUI-Apt_Preset

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

sum_latent Description

Combines two latent samples by summing them, blending features for AI art applications.

sum_latent:

The sum_latent node, also known as LatentAdd, is designed to combine two sets of latent samples by summing them together. This operation is particularly useful in scenarios where you want to merge features or characteristics from two different latent spaces, effectively creating a new latent representation that incorporates elements from both inputs. By adding the latent samples, you can achieve a blend of the underlying features, which can be beneficial in various AI art applications, such as style transfer or feature augmentation. The node ensures that the dimensions of the two input latents are compatible by reshaping the second latent to match the first, allowing for seamless addition. This capability makes the sum_latent node a powerful tool for artists looking to experiment with and manipulate latent spaces to create unique and innovative artworks.

sum_latent Input Parameters:

samples1

samples1 is the first set of latent samples that you want to combine. It serves as the base to which the second set of samples will be added. This parameter is crucial as it determines the initial characteristics and features that will be present in the resulting latent space. There are no specific minimum, maximum, or default values for this parameter, as it depends on the latent data you are working with.

samples2

samples2 is the second set of latent samples that will be added to samples1. This parameter allows you to introduce new features or modify existing ones in the resulting latent space. The node automatically reshapes samples2 to match the dimensions of samples1, ensuring compatibility for the addition operation. Like samples1, there are no specific minimum, maximum, or default values for this parameter.

sum_latent Output Parameters:

samples

The output parameter samples represents the combined latent space resulting from the addition of samples1 and samples2. This output retains the dimensionality of the input samples and contains the merged features from both input sets. The resulting latent space can be used for further processing or as input to other nodes in your AI art workflow, enabling you to explore new creative possibilities.

sum_latent Usage Tips:

  • Ensure that both samples1 and samples2 are properly pre-processed and compatible in terms of their latent space representation to achieve the desired blending effect.
  • Use the sum_latent node to experiment with combining different styles or features from two distinct latent spaces, which can lead to unique and unexpected artistic outcomes.

sum_latent Common Errors and Solutions:

Dimension Mismatch Error

  • Explanation: This error occurs when the dimensions of samples1 and samples2 are incompatible for addition.
  • Solution: Ensure that both input samples are correctly formatted and that samples2 is reshaped to match the dimensions of samples1 using the node's built-in reshaping functionality.

Unexpected Latent Dimensions

  • Explanation: This error arises when the input latent samples do not conform to the expected 4D tensor format.
  • Solution: Verify that your input samples are correctly structured as 4D tensors before passing them to the node. If necessary, adjust the input data to meet this requirement.

sum_latent Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-Apt_Preset
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.