SakeTami
Black Mixture
Black Mixture

patreon


📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows)

👉🏾Prerequisites

GPU Compatibility: 

📂Step 1: Check Your ComfyUI Setup

👩🏾‍💻Step 2: Install Triton

Triton is required for SageAttention to work properly. There are two options here:

1️⃣ Standard Installation:

cd path\to\ComfyUI_windows_portable

(Replace path\to\ComfyUI_windows_portable with your actual folder location.)

python_embeded\python.exe -m pip install -U triton-windows

python_embeded\python.exe -m pip install path\to\triton-3.2.0-cp312-cp312-win_amd64.whl

(Replace path\to\... with the actual file path.)

2️⃣ Pre-release Version (if needed):

If you need the pre-release version (Triton 3.3), use:

python_embeded\python.exe -m pip install -U --pre triton-windows

👨🏾‍💻Step 3: Install Sage Attention

Run this command in the same Command Prompt window:

python_embeded\python.exe -m pip install -U sageattention

Note: If you see a deprecation warning about loading an egg (e.g., sageattention-2.0.1-py3.12-win-amd64.egg), it’s recommended to first upgrade pip:

python_embeded\python.exe -m pip install --upgrade pip

Then force a reinstall if necessary:

python_embeded\python.exe -m pip install --force-reinstall sageattention

🔍Step 4: Install Teacache

Teacache is an optional but useful caching tool that speeds up processing.

Note: You can now install it via the ComfyUI Manager. Open the Manager, go to the "Custom Nodes Manager", search for “comfyui-teacache”, and install it.

or click "Install via Git URL" with https://github.com/welltop-cn/ComfyUI-TeaCache

📂Step 5: Add Missing libs and include Folders

If Triton doesn’t work right away, you may need to add libs and include manually:

🚦Step 6: Verify Installation

🔨Troubleshooting

python_embeded\python.exe -m pip install --force-reinstall sageattention

March 24th, 2025 Update - V1.0

We've put together an EXPERIMENTAL sage attention & triton installer which you can download below. (Still working on the additional features)

  • Place the "BlackMixture-sage-attention-installer.bat" file in your ComfyUI portable root directory.

  • Click "run anyway" if you receive a pop up from Windows Defender. (There's no viruses in this file. You can verify the code by right-clicking and opening with notepad. As I'm not a programmer, this was written using LLMs based on this text guide article)

  • I recommend starting with these options (as the others are more experimental):

    • 1: Check system compatibility

    • 3: Install Triton

    • 4: Install Sage Attention

    • 6: Setup include and libs folders

    • 9: Verify installation

📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows) 📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows) 📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows) 📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows) 📝Easy Guide: Installing Triton, Sage Attention, and Teacache for ComfyUI Portable (Windows)

Comments

copy and pasted my comfyui portable on my 4090 machine, installed the stuff successfully via command line and get this error "Can't import SageAttention: DLL load failed while importing libtriton: A dynamic link library (DLL) initialization routine failed."

backup account

The version of torch will depend on what's compatible with your GPU

Black Mixture

what version of torch is correct for the advanced wan 2.1 workflow ?

Ben Weinstein

Hello, I've installed comfyui with pinokio but I don't have the python embeded_folder, Generally, python seems to be installed in Pinokio\bin\miniconda\Scripts and comfy is installed there (with all regular folders inside) : Pinokio\api\comfy.git Any suggestion?

mojiiito2


More Creators