ComfyUI InfoComfyUI Info

PowerNoiseSuite

Power Noise Suite is a plugin for ComfyUI, succeeding PPF_Noise_ComfyUI. It focuses on latent noise input, diffusion, and latent adjustments. Key updates include an overhauled Power - Law Noise system and a tonal guide image for the Power KSampler. It offers various nodes like Perlin Power Fractal Noise, Power Law Noise, etc., each with specific parameters to generate different noise patterns. The nodes support multiple resampling methods, and some allow for optional VAE encoding. It also provides blending and adjustment functions for latent images, and advanced sampling capabilities with limited sampler compatibility.

WASasquatch

v1.0.0
76 stars
GitHub

Description

Power Noise Suite for ComfyUI

The Power Noise Suite includes nodes focused on latent noise input, diffusion processes, and latent adjustments. This repository succeeds PPF_Noise_ComfyUI.

What's New?

  • Power-Law Noise Overhaul: A complete redesign of the noise system to achieve more accurate noise representation.
  • Tonal Guide Image: The Power KSampler now features a tonal guide image, which can help align generation tone with an input image. While not always reliable, it can strongly theme outputs to match the input image in some cases.

Tonal Guide Workflow Preview

Cross-Hatch Example

Workflows


Installation

  • Clone the repository to ComfyUI/custom_nodes.

Nodage Menu


Nodes

Perlin Power Fractal Noise Parameters

This node generates perlin power fractal noise.

Required:
  • batch_size (int): Number of noisy tensors to generate in the batch.
    Range: [1, 64]
  • width (int): Width of each tensor in pixels.
    Range: [64, 8192]
  • height (int): Height of each image in pixels.
  • resampling (string): Resampling method for scaling noise to latent size. Options:
    • "nearest-exact": Uses nearest-neighbor resampling (blocky, preserves exact values).
    • "bilinear": Weighted average of four nearest pixels (smoother transitions).
    • "area": Antialiasing resampling (reduces artifacts, preserves details).
    • "bicubic": Cubic polynomial interpolation (high-quality resizing).
    • "bislerp": Bilinear sinc interpolation (balances quality and cost).
  • X (float): X-coordinate offset for noise sampling.
    Range: [-99999999, 99999999]
  • Y (float): Y-coordinate offset for noise sampling.
    Range: [-99999999, 99999999]
  • Z (float): Z-coordinate offset for noise sampling.
    Range: [-99999999, 99999999]
  • frame (int): Current frame number for time evolution.
    Range: [0, 99999999]
  • evolution_factor (float): Controls noise evolution over time based on batch index.
    Range: [0.0, 1.0]
  • octaves (int): Number of octaves for fractal generation (detail/complexity).
    Range: [1, 8]
  • persistence (float): Amplitude decrease per octave in fractal generation.
    Range: [0.01, 23.0]
  • lacunarity (float): Frequency increase per octave in fractal generation.
    Range: [0.01, 99.0]
  • exponent (float): Adjusts noise intensity/contrast.
    Range: [0.01, 38.0]
  • scale (float): Scaling factor for noise frequency (larger = smaller patterns).
    Range: [2, 2048]
  • brightness (float): Adjusts overall noise brightness.
    • -1.0 (black), 0.0 (no effect), 1.0 (white).
      Range: [-1.0, 1.0]
  • contrast (float): Adjusts noise contrast.
    • -1.0 (reduced), 0.0 (no effect), 1.0 (increased).
      Range: [-1.0, 1.0]
  • clamp_min (float): Minimum noise value.
    Range: [-10.0, 10]
  • clamp_max (float): Maximum noise value.
    Range: [-10, 10]
  • seed (int, optional): Random seed (uses random seeds per batch if None).
    Range: [0, 0xffffffffffffffff]
  • device (string): Generation device ("cpu" or "cuda").
Optional:
  • optional_vae (VAE, optional): Optional VAE for encoding noise.
Returns
  • latents (LATENT): Resulting latent image.
  • previews (IMAGE): Noise as tensor images.

Power Law Noise Parameters

This node generates Power-Law noise, a common noise type (e.g., "vanilla_comfyui" mode uses white noise).

Input Types
  • batch_size (INT): Batch size for noise generation.
    Default: 1, Range: [1, 64], Step: 1
  • width (INT): Width of generated noise image.
    Default: 512, Range: [64, 8192], Step: 1
  • height (INT): Height of generated noise image.
    Default: 512, Range: [64, 8192], Step: 1
  • resampling (List of Strings): Resampling method.
    Options: ["nearest-exact", "bilinear", "area", "bicubic", "bislerp"]
  • noise_type (List of Strings): Type of power-law noise.
    Options: ["white", "grey", "pink", "green", "blue", "mix"]
  • frequency (FLOAT): Power-law noise frequency.
    Default: 64, Range: [0.001, 1024.0], Step: 0.001
  • attenuation (FLOAT): Attenuation factor for power-law noise.
    Default: 1.0, Range: [0.001, 1024.0], Step: 0.001
  • seed (INT): Random seed.
    Default: 0, Range: [0, 18446744073709551615]
  • device (List of Strings): Generation device.
    Options: ["cpu", "cuda"]
  • optional_vae (VAE): Optional VAE.
    Default: None
Returns
  • latents (LATENT): Resulting latent image.
  • previews (IMAGE): Noise as tensor images.

Cross-Hatch Power Fractal Parameters

This node generates cross-hatch power fractal noise patterns.

Required:
  • batch_size (int): Number of noisy tensors in the batch.
    Range: [1, 64]
  • width (int): Width of each tensor in pixels.
    Range: [64, 8192]
  • height (int): Height of each image in pixels.
  • resampling (string): Resampling method (same options as Perlin Power Fractal Noise).
  • frequency (float): Frequency of the cross-hatch pattern.
    Range: [0.001, 1024.0]
  • octaves (int): Number of octaves (detail/complexity).
    Range: [1, 32]
  • persistence (float): Amplitude decrease per octave.
    Range: [0.001, 2.0]
  • color_tolerance (float): Color variety control.
    Range: [0.001, 1.0]
  • num_colors (int): Number of colors in output.
    Range: [2, 256]
  • angle_degrees (float): Cross-hatch pattern angle.
    Range: [0.0, 360.0]
  • brightness (float): Adjusts overall noise brightness (same range as Perlin).
  • contrast (float): Adjusts noise contrast (same range as Perlin).
  • blur (float): Blur amount.
    Range: [0.0, 1024.0]
  • clamp_min (float): Minimum noise value.
    Range: [-10.0, 10.0]
  • clamp_max (float): Maximum noise value.
    Range: [-10.0, 10.0]
  • seed (int, optional): Random seed (random per batch if None).
    Range: [0, 0xffffffffffffffff]
  • device (string): Generation device ("cpu" or "cuda").
Optional:
  • optional_vae (VAE, optional): Optional VAE for encoding noise.
Returns
  • latents (LATENT): Resulting latent image.
  • previews (IMAGE): Noise as tensor images.

Cross-Hatch Linear Power Fractal Parameters

This node generates linear cross-hatch power fractal noise patterns.

Required Parameters:
  • batch_size (INT): Number of images in the batch.
    Default: 1, Range: [1, 64]
  • width (INT): Image width in pixels.
    Default: 512, Range: [64, 8192]
  • height (INT): Image height in pixels.
    Default: 512, Range: [64, 8192]
  • resampling (STRING): Resampling method (same options as Perlin).
  • frequency (FLOAT): Cross-hatch pattern frequency.
    Default: 320.0, Range: [0.001, 1024.0]
  • gain (FLOAT): Amplitude control for noise.
    Default: 0.25, Range: [0.0, 1.0]
  • octaves (INT): Number of octaves (detail/complexity).
    Default: 12, Range: [1, 32]
  • persistence (FLOAT): Amplitude decrease per octave.
    Default: 1.5, Range: [0.001, 2.0]
  • add_noise (FLOAT): Random noise addition tolerance.
    Default: 0.0, Range: [0.0, 1.0]
  • linear_range (INT): Noise value mapping range.
    Default: 16, Range: [2, 256]
  • linear_tolerance (FLOAT): Color mapping tolerance.
    Default: 0.05, Range: [0.001, 1.0]
  • angle_degrees (FLOAT): Cross-hatch pattern angle.
    Default: 45.0, Range: [0.0, 360.0]
  • brightness (FLOAT): Adjusts noise brightness (same range as Perlin).
  • contrast (FLOAT): Adjusts noise contrast (same range as Perlin).
  • seed (INT): Random seed.
    Default: 0, Range: [0, 0xffffffffffffffff]
  • device (STRING): Generation device ("cpu" or "cuda").
Optional Parameters:
  • optional_vae (VAE): Optional VAE for encoding noise.
Returns
  • latents (LATENT): Resulting latent image.
  • previews (IMAGE): Noise as tensor images.

Blend Latents Parameters

This node blends two latent images.

Required:
  • latent_a (LATENT, required): First input latent image.
  • latent_b (LATENT, required): Second input latent image.
  • operation (string, required): Blending operation. Options:
    • add: Sum pixel values.
    • bislerp: Smooth interpolation with factor t.
    • color dodge: Brighten base image using blend image.
    • cosine interp: Cosine-based interpolation.
    • cuberp: Cubic interpolation.
    • difference: Absolute pixel value difference.
    • exclusion: Exclusion formula (unique contrast).
    • glow: Glow effect (similar to pin light, darker).
    • hard light: High-contrast transition.
    • lerp: Linear interpolation.
    • linear dodge: Brighten via addition.
    • linear light: Contrast-enhancing blend.
    • multiply: Multiply pixel values (darker output).
    • overlay: Overlay formula (dramatic contrast).
    • pin light: Detail-preserving color intensification.
    • random: Add random noise.
    • reflect: Reflection-based blend.
    • screen: Brighten via screen formula.
    • slerp: Spherical interpolation.
    • subtract: Subtract blend image from base.
    • vivid light: Color vividness enhancement.
  • blend_ratio (FLOAT, required): Blend ratio between latent_a and latent_b.
    Default: 0.5, Range: [0.01, 1.0]
  • blend_strength (FLOAT, required): Blending operation strength.
    Default: 1.0, Range: [0.0, 100.0]
Optional:
  • mask (MASK, optional): Mask tensor to control blending region.
  • set_noise_mask (string, optional): Enable noise mask ("false" or "true").
  • normalize (string, optional): Normalize output latent ("false" or "true").
  • clamp_min (FLOAT, optional): Minimum output value.
    Default: 0.0, Range: [-10.0, 10.0]
  • clamp_max (FLOAT, optional): Maximum output value.
    Default: 1.0, Range: [-10.0, 10.0]
Returns
  • latent (LATENT): Blended latent image.

Images as Latents Parameters

This node converts IMAGE to LATENT format (primarily for raw noise).

Required:
  • images (IMAGE): Input images to convert.
  • resampling (string): Resampling method (same options as Perlin).
Returns
  • tuple (LATENT, IMAGE): Converted latent image and input images.

Latent Adjustment Parameters

This node adjusts latent images (brightness, contrast, sharpness).

Required Inputs
  • latents (LATENT): Input latent image.
  • brightness (FLOAT): Brightness adjustment.
    Default: 1.0, Range: [-1.0, 2.0], Step: 0.001
  • contrast (FLOAT): Contrast adjustment.
    Default: 1.0, Range: [-1.0, 2.0], Step: 0.001
  • saturation (FLOAT): Saturation adjustment.
    Default: 1.0, Range: [0.0, 2.0], Step: 0.0