ComfyUI > Nodes > ComfyUI_StreamDiffusion > StreamDiffusion_Sampler

ComfyUI Node: StreamDiffusion_Sampler

Class Name

StreamDiffusion_Sampler

Category
StreamDiffusion/Sampler
Author
jesenzhang (Account age: 3653days)
Extension
ComfyUI_StreamDiffusion
Latest Updated
2024-05-23
Github Stars
0.11K

How to Install ComfyUI_StreamDiffusion

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

StreamDiffusion_Sampler Description

Powerful node for high-quality image generation using diffusion models, seamlessly integrated with StreamDiffusion pipeline for efficient sampling.

StreamDiffusion_Sampler:

The StreamDiffusion_Sampler is a powerful node designed to facilitate the generation of high-quality images using diffusion models. This node leverages advanced techniques to ensure that the generated images are both realistic and adhere to the specified prompts. It integrates seamlessly with the StreamDiffusion pipeline, allowing for efficient and effective image sampling. The node is capable of handling various configurations, including the use of safety checkers to filter out inappropriate content, and can be customized with different parameters to suit specific artistic needs. By utilizing this node, you can achieve consistent and high-quality results in your AI art projects.

StreamDiffusion_Sampler Input Parameters:

seed

The seed parameter is used to initialize the random number generator for the diffusion process. If set to a value less than 0, a random seed will be generated. This parameter ensures reproducibility of the generated images. The default value is a random integer between 0 and 1,000,000.

num_inference_steps

The num_inference_steps parameter determines the number of steps the diffusion process will take to generate an image. More steps generally lead to higher quality images but will take longer to compute. The default value is 50.

guidance_scale

The guidance_scale parameter controls the influence of the prompt on the generated image. Higher values make the image more closely follow the prompt, while lower values allow for more creative freedom. The default value is 1.1 if the cfg_type is "full", "self", or "initialize", otherwise it is 1.0.

use_safety_checker

The use_safety_checker parameter enables or disables the safety checker, which filters out NSFW (Not Safe For Work) content. When enabled, the node uses the StableDiffusionSafetyChecker and CLIPFeatureExtractor to ensure the generated images are appropriate. The default value is True.

prompt

The prompt parameter is the textual description that guides the image generation process. It can be updated dynamically to influence the generated image. There is no default value, and it must be provided by the user.

negative_prompt

The negative_prompt parameter is used to specify elements that should be avoided in the generated image. It works in conjunction with the prompt to refine the output. There is no default value, and it must be provided by the user if needed.

frame_buffer_size

The frame_buffer_size parameter determines the size of the buffer used during the image generation process. A larger buffer size can improve performance but requires more memory. The default value is 1.

use_denoising_batch

The use_denoising_batch parameter enables batch processing for denoising, which can speed up the image generation process. The default value is False.

similar_image_filter_threshold

The similar_image_filter_threshold parameter sets the threshold for the similar image filter, which removes images that are too similar to previously generated ones. This helps in maintaining diversity in the generated images. The default value is not specified and should be set based on user requirements.

similar_image_filter_max_skip_frame

The similar_image_filter_max_skip_frame parameter defines the maximum number of frames to skip when using the similar image filter. This helps in balancing between diversity and computational efficiency. The default value is not specified and should be set based on user requirements.

StreamDiffusion_Sampler Output Parameters:

image

The image parameter is the final output of the node, representing the generated image. This image is processed and filtered based on the input parameters and safety checks, ensuring it meets the specified criteria and quality standards.

StreamDiffusion_Sampler Usage Tips:

  • To achieve consistent results, set a specific seed value. This allows you to reproduce the same image in future runs.
  • Adjust the num_inference_steps to balance between image quality and generation time. More steps generally yield better quality but take longer.
  • Use the guidance_scale to fine-tune how closely the generated image follows the prompt. Higher values make the image more prompt-specific.
  • Enable the use_safety_checker to ensure that the generated images are appropriate and free from NSFW content.
  • Experiment with the prompt and negative_prompt to guide the image generation process effectively. Be specific in your descriptions for better results.

StreamDiffusion_Sampler Common Errors and Solutions:

"CUDA out of memory"

  • Explanation: This error occurs when the GPU runs out of memory during the image generation process.
  • Solution: Reduce the num_inference_steps or frame_buffer_size, or use a GPU with more memory.

"Invalid seed value"

  • Explanation: This error occurs when the seed parameter is set to an invalid value.
  • Solution: Ensure that the seed is an integer. If you want a random seed, set it to a value less than 0.

"Prompt not provided"

  • Explanation: This error occurs when the prompt parameter is not provided.
  • Solution: Ensure that you provide a valid textual description in the prompt parameter to guide the image generation process.

"Safety checker model not found"

  • Explanation: This error occurs when the safety checker model cannot be loaded.
  • Solution: Ensure that the required models (StableDiffusionSafetyChecker and CLIPFeatureExtractor) are correctly installed and accessible.

"Image filter threshold not set"

  • Explanation: This error occurs when the similar_image_filter_threshold is not set but the similar image filter is enabled.
  • Solution: Set a valid threshold value for the similar_image_filter_threshold parameter to enable the similar image filter.

StreamDiffusion_Sampler Related Nodes

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