[Partner Nodes] feat(client): consume estimated-duration headers for progress display (#16152)
- [Partner Nodes] feat(client): consume estimated-duration headers for progress display
Signed-off-by: bigcat88 bigcat88@icloud.com
- [Partner Nodes] refactor(client): remove the inert sync-op estimated_duration parameter
Signed-off-by: bigcat88 bigcat88@icloud.com
- [Partner Nodes] fix(client): harden polling against interrupt races and transient extractor failures
Signed-off-by: bigcat88 bigcat88@icloud.com
- [Partner Nodes] refactor(client): drop inert defensive code in estimate parsing and progress math
Signed-off-by: bigcat88 bigcat88@icloud.com
Signed-off-by: bigcat88 bigcat88@icloud.com
版权所有:中国计算机学会技术支持:开源发展技术委员会
京ICP备13000930号-9
京公网安备 11010802047560号
ComfyUI
The most powerful and modular AI engine for content creation.
ComfyUI is the AI creation engine for visual professionals who demand control over every model, every parameter, and every output. Its powerful and modular node graph interface empowers creatives to generate images, videos, 3D models, audio, and more…
Get Started
Local
Desktop Application
Manual Install
Supports all operating systems and GPU types (NVIDIA, AMD, Intel, Apple Silicon, Ascend).
Cloud
Comfy Cloud
Examples
See what ComfyUI can do with the newer template workflows or old example workflows.
Features
--disable-api-nodesto disable the optional paid Comfy API nodes and force all built-in functionality to stay offline.extra_model_paths.yaml.Release Process
ComfyUI follows a weekly release cycle targeting Monday but this regularly changes because of model releases or large changes to the codebase. There are three interconnected repositories:
ComfyUI Core
Comfy Desktop
ComfyUI Frontend
Shortcuts
Ctrl+EnterCtrl+Shift+EnterCtrl+Alt+EnterCtrl+Z/Ctrl+YCtrl+SCtrl+OCtrl+AAlt+CCtrl+MCtrl+BDelete/BackspaceCtrl+BackspaceSpaceCtrl/Shift+ClickCtrl+C/Ctrl+VCtrl+C/Ctrl+Shift+VShift+DragCtrl+DAlt++Alt+-Ctrl+Shift+ LMB + Vertical dragPCtrl+GQHRF.Shift+ DragCtrl+Alt+ LMBCtrlcan also be replaced withCmdinstead for macOS usersInstalling
Windows and Mac
We highly recommend using the desktop app:
Link to Download
The desktop app is the easiest and best way to use ComfyUI for new users.
Windows Portable
There is a portable standalone build for Windows that should work for running on Nvidia GPUs or for running on your CPU only. It is not recommended for regular users. Regular users should use the desktop app above.
Direct link to download (nvidia)
Simply download, extract with 7-Zip or with the windows explorer on recent windows versions and run. For smaller models you normally only need to put the checkpoints (the huge ckpt/safetensors files) in: ComfyUI\models\checkpoints but many of the larger models have multiple files. Make sure to follow the instructions to know which subfolder to put them in ComfyUI\models\
If you have trouble extracting it, right click the file -> properties -> unblock
The portable above currently comes with python 3.13 and pytorch cuda 13.0. Update your Nvidia drivers if it doesn’t start.
All Official Portable Downloads:
Portable for AMD GPUs
Portable for Intel GPUs
Portable for Nvidia GPUs (supports 20 series and above).
Portable for Nvidia GPUs with pytorch cuda 12.6 and python 3.12 (Supports Nvidia 10 series and older GPUs, DO NOT USE THIS ON NEWER 20 SERIES AND ABOVE GPUS).
How do I share models between another UI and ComfyUI?
See the Config file to set the search paths for models. In the standalone windows build you can find this file in the ComfyUI directory. Rename this file to extra_model_paths.yaml and edit it with your favorite text editor.
comfy-cli
You can install and start ComfyUI using comfy-cli:
Manual Install (Windows, Linux)
Python 3.14 works but some custom nodes may have issues. The free threaded variant works but some dependencies will enable the GIL so it’s not fully supported.
Python 3.13 is very well supported. If you have trouble with some custom node dependencies on 3.13 you can try 3.12
torch 2.7 is minimally supported but using a newer version is extremely recommended. Using a cu130 or above version of pytorch is required on Nvidia 20 series and above. Some features and optimizations might only work on newer versions. We generally recommend using the latest major version of pytorch with the latest cuda version unless it is less than 2 weeks old. If your pytorch is more than 6 months old, please update it.
Instructions:
Git clone this repo.
Put your SD checkpoints (the huge ckpt/safetensors files) in: models/checkpoints
Put your VAE in: models/vae
AMD GPUs (Linux)
AMD users can install rocm and pytorch with pip if you don’t have it already installed, this is the command to install the stable version:
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm7.2This is the command to install the nightly with ROCm 7.2 which might have some performance improvements:
pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/rocm7.2AMD GPUs (Windows, ROCm 10.0)
Use AMD’s multi-architecture PyTorch packages. The
device-*extras install your GPU’s kernels and the matching ROCm runtime automatically; a separate HIP SDK installation is not needed.Use Windows 11, a current AMD graphics driver, and 64-bit Python 3.13.
The install command below uses
device-allto install kernels for all supported GPUs. To reduce download size and disk usage, optionally replace both occurrences ofdevice-allwith the target for your GPU:device-gfx1201device-gfx1200device-gfx1100device-gfx1101device-gfx1102device-gfx1151Note: This table only lists examples. A GPU missing from it may still be supported: supported architectures include RDNA 2, RDNA 3, RDNA 3.5, and RDNA 4. Keep
device-allto install kernels for all supported targets. For other models, see AMD’s GPU target table and ROCm compatibility matrix.ROCm 10.0.0 with PyTorch 2.13:
Intel GPUs (Windows and Linux)
Intel Arc GPU users can install native PyTorch with torch.xpu support using pip. More information can be found here
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/xpuThis is the command to install the Pytorch xpu nightly which might have some performance improvements:
pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/xpuNVIDIA
Nvidia users should install stable pytorch using this command:
pip install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu130This is the command to install pytorch nightly instead which might have performance improvements.
pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu132Troubleshooting
If you get the “Torch not compiled with CUDA enabled” error, uninstall torch with:
pip uninstall torchAnd install it again with the command above.
Dependencies
Install the dependencies by opening your terminal inside the ComfyUI folder and:
pip install -r requirements.txtAfter this you should have everything installed and can proceed to running ComfyUI.
Others:
Apple Mac silicon
You can install ComfyUI in Apple Mac silicon (M1, M2, M3 or M4) with any recent macOS version.
python main.pyAscend NPUs
For models compatible with Ascend Extension for PyTorch (torch_npu). To get started, ensure your environment meets the prerequisites outlined on the installation page. Here’s a step-by-step guide tailored to your platform and installation method:
Cambricon MLUs
For models compatible with Cambricon Extension for PyTorch (torch_mlu). Here’s a step-by-step guide tailored to your platform and installation method:
python main.pyIluvatar Corex
For models compatible with Iluvatar Extension for PyTorch. Here’s a step-by-step guide tailored to your platform and installation method:
python main.pyComfyUI-Manager
ComfyUI-Manager is an extension that allows you to easily install, update, and manage custom nodes for ComfyUI.
Setup
Install the manager dependencies:
Enable the manager with the
--enable-managerflag when running ComfyUI:Command Line Options
--enable-manager--enable-manager-legacy-ui--enable-manager)--disable-manager-ui--enable-manager)Running
python main.pyFor AMD cards not officially supported by ROCm
Try running it with this command if you have issues:
For 6700, 6600 and maybe other RDNA2 or older:
HSA_OVERRIDE_GFX_VERSION=10.3.0 python main.pyFor AMD 7600 and maybe other RDNA3 cards:
HSA_OVERRIDE_GFX_VERSION=11.0.0 python main.pyAMD ROCm Tips
You can try setting this env variable
PYTORCH_TUNABLEOP_ENABLED=1which might speed things up at the cost of a very slow initial run.Notes
Only parts of the graph that have an output with all the correct inputs will be executed.
Only parts of the graph that change from each execution to the next will be executed, if you submit the same graph twice only the first will be executed. If you change the last part of the graph only the part you changed and the part that depends on it will be executed.
Dragging a generated png on the webpage or loading one will give you the full workflow including seeds that were used to create it.
You can use () to change emphasis of a word or phrase like: (good code:1.2) or (bad code:0.8). The default emphasis for () is 1.1. To use () characters in your actual prompt escape them like \( or \).
You can use {day|night}, for wildcard/dynamic prompts. With this syntax “{wild|card|test}” will be randomly replaced by either “wild”, “card” or “test” by the frontend every time you queue the prompt. To use {} characters in your actual prompt escape them like: \{ or \}.
Dynamic prompts also support C-style comments, like
// commentor/* comment */.To use a textual inversion concepts/embeddings in a text prompt put them in the models/embeddings directory and use them in the CLIPTextEncode node like this (you can omit the .pt extension):
embedding:embedding_filename.ptHow to show high-quality previews?
Use
--preview-method autoto enable previews.The default installation includes a fast latent preview method that’s low-resolution. To enable higher-quality previews with TAESD, download the taesd_decoder.pth, taesdxl_decoder.pth, taesd3_decoder.pth and taef1_decoder.pth and place them in the
models/vae_approxfolder. Once they’re installed, restart ComfyUI and launch it with--preview-method taesdto enable high-quality previews.How to use TLS/SSL?
Generate a self-signed certificate (not appropriate for shared/production use) and key by running the command:
openssl req -x509 -newkey rsa:4096 -keyout key.pem -out cert.pem -sha256 -days 3650 -nodes -subj "/C=XX/ST=StateName/L=CityName/O=CompanyName/OU=CompanySectionName/CN=CommonNameOrHostname"Use
--tls-keyfile key.pem --tls-certfile cert.pemto enable TLS/SSL, the app will now be accessible withhttps://...instead ofhttp://....Support and dev channel
Discord: Try the #help or #feedback channels.
Matrix space: #comfyui_space:matrix.org (it’s like discord but open source).
See also: https://www.comfy.org/
Frontend Development
As of August 15, 2024, we have transitioned to a new frontend, which is now hosted in a separate repository: ComfyUI Frontend. The compiled JS files (from TS/Vue) are published to pypi and installed as a dependency in ComfyUI.
Reporting Issues and Requesting Features
For any bugs, issues, or feature requests related to the frontend, please use the ComfyUI Frontend repository. This will help us manage and address frontend-specific concerns more efficiently.
Using the Latest Frontend
The new frontend is now the default for ComfyUI. However, please note:
To use the most up-to-date frontend version:
For the latest daily release, launch ComfyUI with this command line argument:
For a specific version, replace
latestwith the desired version number:This approach allows you to easily switch between the stable fortnightly release and the cutting-edge daily updates, or even specific versions for testing purposes.
QA
Which GPU should I buy for this?
See this page for some recommendations