Comfy-Org / Comfy-Org/comfy-kitchen
ck-attention STILL crashes on AMD after #104 fix
- Dominant language
- Python
- Stars
- 220
- Forks
- 91
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 12
Description
ck-attention STILL crashes on AMD after #104 fix.
My system:
win 11, gfx 1151 (AMD Radeon 8060s), python 3.12, using AMD pytorch from https://repo.radeon.com/rocm/windows/rocm-rel-7.2.1/
```
pip install `
-f https://repo.radeon.com/rocm/windows/rocm-rel-7.2.1/ `
"torch==2.9.1+rocm7.2.1" `
"torchvision==0.24.1+rocm7.2.1" `
"torchaudio==2.9.1+rocm7.2.1" `
numpy pillow
```
PYPI package hadn't updated yet, so I grabbed the windows 3.12 amd whl from the build artifact: https://github.com/Comfy-Org/comfy-kitchen/actions/runs/31491146906/artifacts/9101500506
Steps to reproduce:
I did a force reinstall of the new whl
`python -m pip install --no-cache-dir --force-reinstall comfy_kitchen-0.2.30-cp312-abi3-win_amd64.whl`
then ran comfyui
`python main.py --listen 127.0.0.1 --port 8188 --use-ck-attention`
Then just loaded the comfy WF templates for minimax h3 Image-to-video and text-to-video - no modifications, I just ran each.
**Note: I did notice in the start up log**
```
[INFO] Using pytorch attention
[INFO] Using Comfy Kitchen attention
```
_I thought it should only show one attention not both?_
anyways, after models load up and sampler starts processing, here is the error:
**(NOTE - I ran this test for these test combinations and got the same error
1. Image-to-video with global flag --use-ck-attention and no mods
2. Text-to-video with global flag --use-ck-attention and no mods
3. Image-to-video restart comfy without global flag --use-ck-attention and added backend node
4. Text-to-video restart comfy without global flag --use-ck-attention and added backend node
)**
error:
```
[INFO] got prompt
[INFO] VAE load device: cuda:0, offload device: cpu, dtype: torch.float32
[INFO] VAE load device: cuda:0, offload device: cpu, dtype: torch.float16
[INFO] Found quantization metadata version 1
[INFO] Using MixedPrecisionOps for text encoder
[INFO] Requested to load MiniMaxH3TEModel_
[INFO] loaded completely; 14960.20 MB loaded, full load: True
[INFO] CLIP/text encoder model load device: cuda:0, offload device: cpu, current: cuda:0, dtype: torch.float16
C:\AI\Comfyui-amd-20260805\ComfyUI\comfy\ops.py:95: UserWarning: Using AOTriton backend for Efficient Attention forward... (Triggered internally at C:/b/pytorch/aten/src/ATen/native/transformers/hip/attention.hip:1452.)
return torch.nn.functional.scaled_dot_product_attention(q, k, v, *args, **kwargs)
[INFO] Found quantization metadata version 1
[INFO] Detected mixed precision quantization
[INFO] Using mixed precision operations
[INFO] Native ops: int8_tensorwise, asym_w4a8_int8, convrot_w4a4 , emulated ops: float8_e4m3fn, mxfp8, nvfp4, float8_e5m2
[INFO] model weight dtype torch.bfloat16, manual cast: torch.bfloat16
[INFO] model_type FLOW_AV
[INFO] Requested to load MiniMaxH3
[INFO] loaded completely; 70683.17 MB usable, 19996.14 MB loaded, full load: True
0%| | 0/20 [00:00
Contributor guide
Research direction
Reproduce the crash with the MiniMax H3 image-to-video and text-to-video workflows using the --use-ck-attention flag and the backend node variant. Start at comfy/ops.py:95 and the traceback's comfy/ldm/minimax/model.py:502, then trace the sage int8 attention path; done means both workflows run without the Q/K pointer and stride alignment error and attention selection is understood.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, pytorch
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100