WanVideoModelLoader - No module named 'sageattention'
ComfyUI Error Report
Error Details
- Node ID: 22
- Node Type: WanVideoModelLoader
- Exception Type: ValueError
- Exception Message: Can't import SageAttention: No module named 'sageattention'
Stack Trace
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 327, in execute
output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 202, in get_output_data
return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 174, in _map_node_over_list
process_inputs(input_dict, i)
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 163, in process_inputs
results.append(getattr(obj, func)(**inputs))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\nodes.py", line 166, in loadmodel
raise ValueError(f"Can't import SageAttention: {str(e)}")
System Information
- ComfyUI Version: 0.3.14
- Arguments: ComfyUI\main.py
- OS: nt
- Python Version: 3.12.8 (tags/v3.12.8:2dc476b, Dec 3 2024, 19:30:04) [MSC v.1942 64 bit (AMD64)]
- Embedded Python: true
- PyTorch Version: 2.6.0+cu126
Devices
- Name: cuda:0 NVIDIA GeForce RTX 3090 : cudaMallocAsync
- Type: cuda
- VRAM Total: 25769279488
- VRAM Free: 23607384576
- Torch VRAM Total: 905969664
- Torch VRAM Free: 157030912
Logs
2025-02-26T09:12:33.087671 - [START] Security scan2025-02-26T09:12:33.087671 -
2025-02-26T09:12:33.937302 - [DONE] Security scan2025-02-26T09:12:33.937302 -
2025-02-26T09:12:34.073768 - ## ComfyUI-Manager: installing dependencies done.2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** ComfyUI startup time:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - 2025-02-26 09:12:34.0732025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** Platform:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - Windows2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** Python version:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - 3.12.8 (tags/v3.12.8:2dc476b, Dec 3 2024, 19:30:04) [MSC v.1942 64 bit (AMD64)]2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** Python executable:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\python_embeded\python.exe2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** ComfyUI Path:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** ComfyUI Base Folder Path:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** User directory:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\user2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** ComfyUI-Manager config path:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\user\default\ComfyUI-Manager\config.ini2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.073768 - ** Log path:2025-02-26T09:12:34.073768 - 2025-02-26T09:12:34.073768 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\user\comfyui.log2025-02-26T09:12:34.073768 -
2025-02-26T09:12:34.913168 -
Prestartup times for custom nodes:
2025-02-26T09:12:34.913168 - 2.6 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-manager
2025-02-26T09:12:34.913168 -
2025-02-26T09:12:36.800206 - Checkpoint files will always be loaded safely.
2025-02-26T09:12:36.925167 - Total VRAM 24576 MB, total RAM 32610 MB
2025-02-26T09:12:36.925167 - pytorch version: 2.6.0+cu126
2025-02-26T09:12:36.926170 - Set vram state to: NORMAL_VRAM
2025-02-26T09:12:36.926170 - Device: cuda:0 NVIDIA GeForce RTX 3090 : cudaMallocAsync
2025-02-26T09:12:38.598611 - Using pytorch attention
2025-02-26T09:12:40.670628 - ComfyUI version: 0.3.14
2025-02-26T09:12:40.696060 - [Prompt Server] web root: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\web
2025-02-26T09:12:42.141318 - Total VRAM 24576 MB, total RAM 32610 MB
2025-02-26T09:12:42.141318 - pytorch version: 2.6.0+cu126
2025-02-26T09:12:42.141318 - Set vram state to: NORMAL_VRAM
2025-02-26T09:12:42.142318 - Device: cuda:0 NVIDIA GeForce RTX 3090 : cudaMallocAsync
2025-02-26T09:12:42.647952 - ### Loading: ComfyUI-Manager (V3.27)
2025-02-26T09:12:42.647952 - [ComfyUI-Manager] network_mode: public
2025-02-26T09:12:42.747121 - ### ComfyUI Revision: 3109 [debabccb] *DETACHED | Released on '2025-02-05'
2025-02-26T09:12:43.212613 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/alter-list.json
2025-02-26T09:12:43.231842 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/model-list.json
2025-02-26T09:12:43.320846 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/github-stats.json
2025-02-26T09:12:43.370676 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/extension-node-map.json
2025-02-26T09:12:43.390527 - [ComfyUI-Manager] default cache updated: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json
2025-02-26T09:12:43.455252 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\wanvideo\modules\model.py:28: FutureWarning: `torch.cuda.amp.autocast(args...)` is deprecated. Please use `torch.amp.autocast('cuda', args...)` instead.
@amp.autocast(enabled=False)
2025-02-26T09:12:43.456252 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\wanvideo\modules\model.py:41: FutureWarning: `torch.cuda.amp.autocast(args...)` is deprecated. Please use `torch.amp.autocast('cuda', args...)` instead.
@amp.autocast(enabled=False)
2025-02-26T09:12:43.601790 - [36;20m[comfy_mtb] | INFO -> loaded [96m95[0m nodes successfuly[0m
2025-02-26T09:12:43.602789 - [36;20m[comfy_mtb] | INFO -> Some nodes (5) could not be loaded. This can be ignored, but go to http://127.0.0.1:8188/mtb if you want more information.[0m
2025-02-26T09:12:43.624603 -
Import times for custom nodes:
2025-02-26T09:12:43.624708 - 0.0 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\websocket_image_save.py
2025-02-26T09:12:43.624708 - 0.0 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Custom-Scripts
2025-02-26T09:12:43.624708 - 0.0 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\mikey_nodes
2025-02-26T09:12:43.624708 - 0.0 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-GGUF
2025-02-26T09:12:43.624708 - 0.0 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main
2025-02-26T09:12:43.625762 - 0.1 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-KJNodes
2025-02-26T09:12:43.625762 - 0.1 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfy_mtb
2025-02-26T09:12:43.625762 - 0.2 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-VideoHelperSuite
2025-02-26T09:12:43.625762 - 0.3 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-manager
2025-02-26T09:12:43.625762 - 0.3 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\comfyui-tensorops
2025-02-26T09:12:43.625762 - 0.4 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-Florence2
2025-02-26T09:12:43.625762 - 0.4 seconds: D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-LTXVideo
2025-02-26T09:12:43.625762 -
2025-02-26T09:12:43.634761 - Starting server
2025-02-26T09:12:43.634761 - To see the GUI go to: http://127.0.0.1:8188
2025-02-26T09:12:48.604544 - FETCH ComfyRegistry Data: 5/352025-02-26T09:12:48.605544 -
2025-02-26T09:12:53.842096 - FETCH ComfyRegistry Data: 10/352025-02-26T09:12:53.843096 -
2025-02-26T09:12:59.917894 - FETCH ComfyRegistry Data: 15/352025-02-26T09:12:59.918893 -
2025-02-26T09:13:05.549629 - FETCH ComfyRegistry Data: 20/352025-02-26T09:13:05.549629 -
2025-02-26T09:13:11.471657 - FETCH ComfyRegistry Data: 25/352025-02-26T09:13:11.471657 -
2025-02-26T09:13:17.110899 - FETCH ComfyRegistry Data: 30/352025-02-26T09:13:17.111900 -
2025-02-26T09:13:22.132456 - FETCH ComfyRegistry Data: 35/352025-02-26T09:13:22.132456 -
2025-02-26T09:13:22.633936 - FETCH ComfyRegistry Data [DONE]2025-02-26T09:13:22.633936 -
2025-02-26T09:13:22.665528 - [ComfyUI-Manager] default cache updated: https://api.comfy.org/nodes
2025-02-26T09:13:22.678590 - nightly_channel: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/remote
2025-02-26T09:13:22.678590 - FETCH DATA from: https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/custom-node-list.json2025-02-26T09:13:22.678590 - 2025-02-26T09:13:23.096873 - [DONE]2025-02-26T09:13:23.099354 -
2025-02-26T09:13:23.127480 - [ComfyUI-Manager] All startup tasks have been completed.
2025-02-26T09:14:12.595550 - Exception in callback _ProactorBasePipeTransport._call_connection_lost(None)
handle: <Handle _ProactorBasePipeTransport._call_connection_lost(None)>
Traceback (most recent call last):
File "asyncio\events.py", line 88, in _run
File "asyncio\proactor_events.py", line 165, in _call_connection_lost
ConnectionResetError: [WinError 10054] Удаленный хост принудительно разорвал существующее подключение
2025-02-26T09:14:28.096936 - got prompt
2025-02-26T09:14:28.096936 - Failed to validate prompt for output 30:
2025-02-26T09:14:28.096936 - * WanVideoModelLoader 22:
2025-02-26T09:14:28.096936 - - Value not in list: model: 'WanVideo\Wan2_1-I2V-14B-480P_fp8_e4m3fn.safetensors' not in ['Wan2_1-I2V-14B-480P_fp8_e4m3fn.safetensors', 'Wan2_1-I2V-14B-720P_fp8_e4m3fn.safetensors']
2025-02-26T09:14:28.096936 - Output will be ignored
2025-02-26T09:14:28.096936 - invalid prompt: {'type': 'prompt_outputs_failed_validation', 'message': 'Prompt outputs failed validation', 'details': '', 'extra_info': {}}
2025-02-26T09:14:53.522343 - got prompt
2025-02-26T09:15:00.517064 - D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\wanvideo\modules\clip.py:532: FutureWarning: `torch.cuda.amp.autocast(args...)` is deprecated. Please use `torch.amp.autocast('cuda', args...)` instead.
with torch.cuda.amp.autocast(dtype=self.dtype):
2025-02-26T09:15:22.006324 - !!! Exception during processing !!! Can't import SageAttention: No module named 'sageattention'
2025-02-26T09:15:22.009660 - Traceback (most recent call last):
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\nodes.py", line 164, in loadmodel
from sageattention import sageattn
ModuleNotFoundError: No module named 'sageattention'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 327, in execute
output_data, output_ui, has_subgraph = get_output_data(obj, input_data_all, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 202, in get_output_data
return_values = _map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True, execution_block_cb=execution_block_cb, pre_execute_cb=pre_execute_cb)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 174, in _map_node_over_list
process_inputs(input_dict, i)
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\execution.py", line 163, in process_inputs
results.append(getattr(obj, func)(**inputs))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "D:\Comfy\ComfyUI_windows_portable_nvidia\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-WanVideoWrapper-main\nodes.py", line 166, in loadmodel
raise ValueError(f"Can't import SageAttention: {str(e)}")
ValueError: Can't import SageAttention: No module named 'sageattention'
2025-02-26T09:15:22.011678 - Prompt executed in 28.48 seconds
Attached Workflow
Please make sure that workflow does not contain any sensitive information such as API keys or passwords.
{"last_node_id":36,"last_link_id":40,"nodes":[{"id":18,"type":"LoadImage","pos":[417.39227294921875,529.9345092773438],"size":[315,314],"flags":{},"order":0,"mode":0,"inputs":[],"outputs":[{"name":"IMAGE","type":"IMAGE","links":[18]},{"name":"MASK","type":"MASK","links":null}],"properties":{"cnr_id":"comfy-core","ver":"0.3.14","Node name for S&R":"LoadImage"},"widgets_values":["25986-00001-00453-1218063589-3408-photorealistic of 65 yo business woman , (aged_1.6), Paris at night, (thigh high boots_1.2), choker, flower, intricate, elegant.png","image"]},{"id":32,"type":"WanVideoBlockSwap","pos":[232.6178741455078,-338.61407470703125],"size":[315,58],"flags":{},"order":1,"mode":0,"inputs":[],"outputs":[{"name":"block_swap_args","type":"BLOCKSWAPARGS","links":[39],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoBlockSwap"},"widgets_values":[10]},{"id":11,"type":"LoadWanVideoT5TextEncoder","pos":[224.15325927734375,-34.481563568115234],"size":[377.1661376953125,115.05413055419922],"flags":{},"order":2,"mode":0,"inputs":[],"outputs":[{"name":"wan_t5_model","type":"WANTEXTENCODER","links":[15],"slot_index":0}],"properties":{"Node name for S&R":"LoadWanVideoT5TextEncoder"},"widgets_values":["umt5-xxl-enc-bf16.safetensors","bf16","offload_device"]},{"id":13,"type":"LoadWanVideoClipTextEncoder","pos":[153.7196502685547,226.0297088623047],"size":[510.6601257324219,106],"flags":{},"order":3,"mode":0,"inputs":[],"outputs":[{"name":"wan_clip_model","type":"WANCLIP","links":[17],"slot_index":0}],"properties":{"Node name for S&R":"LoadWanVideoClipTextEncoder"},"widgets_values":["open-clip-xlm-roberta-large-vit-huge-14_fp16.safetensors","fp16","offload_device"]},{"id":28,"type":"WanVideoDecode","pos":[1319.96875,11.251319885253906],"size":[315,174],"flags":{},"order":13,"mode":0,"inputs":[{"name":"vae","type":"WANVAE","link":34},{"name":"samples","type":"LATENT","link":33}],"outputs":[{"name":"images","type":"IMAGE","links":[36],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoDecode"},"widgets_values":[true,272,272,144,128]},{"id":33,"type":"Note","pos":[227.3764190673828,-205.28524780273438],"size":[351.70458984375,60],"flags":{},"order":4,"mode":0,"inputs":[],"outputs":[],"properties":{},"widgets_values":["Models:\nhttps://huggingface.co/Kijai/WanVideo_comfy/tree/main"],"color":"#432","bgcolor":"#653"},{"id":30,"type":"VHS_VideoCombine","pos":[1712.420654296875,-353.76507568359375],"size":[214.7587890625,334],"flags":{},"order":14,"mode":0,"inputs":[{"name":"images","type":"IMAGE","link":36},{"name":"audio","type":"AUDIO","link":null,"shape":7},{"name":"meta_batch","type":"VHS_BatchManager","link":null,"shape":7},{"name":"vae","type":"VAE","link":null,"shape":7}],"outputs":[{"name":"Filenames","type":"VHS_FILENAMES","links":null}],"properties":{"cnr_id":"comfyui-videohelpersuite","ver":"4c7858ddd5126f7293dc3c9f6e0fc4c263cde079","Node name for S&R":"VHS_VideoCombine"},"widgets_values":{"frame_rate":16,"loop_count":0,"filename_prefix":"WanVideo2_1","format":"video/h264-mp4","pix_fmt":"yuv420p","crf":19,"save_metadata":true,"trim_to_audio":false,"pingpong":false,"save_output":true,"videopreview":{"hidden":false,"paused":false,"params":{"filename":"WanVideo2_1_00011.mp4","subfolder":"","type":"output","format":"video/h264-mp4","frame_rate":16,"workflow":"WanVideo2_1_00011.png","fullpath":"N:\\AI\\ComfyUI\\output\\WanVideo2_1_00011.mp4"}}}},{"id":27,"type":"WanVideoSampler","pos":[1315.2401123046875,-356.4367980957031],"size":[315,310],"flags":{},"order":12,"mode":0,"inputs":[{"name":"model","type":"WANVIDEOMODEL","link":29},{"name":"text_embeds","type":"WANVIDEOTEXTEMBEDS","link":30},{"name":"image_embeds","type":"WANVIDIMAGE_EMBEDS","link":32},{"name":"samples","type":"LATENT","link":null,"shape":7}],"outputs":[{"name":"samples","type":"LATENT","links":[33],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoSampler"},"widgets_values":[10,6,5,1057359483639286,"fixed",true,"dpm++",0,1]},{"id":35,"type":"WanVideoTorchCompileSettings","pos":[124.67726135253906,-627.7935180664062],"size":[390.5999755859375,178],"flags":{},"order":5,"mode":0,"inputs":[],"outputs":[{"name":"torch_compile_args","type":"WANCOMPILEARGS","links":[],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoTorchCompileSettings"},"widgets_values":["inductor",false,"default",false,64,true]},{"id":34,"type":"Note","pos":[912.0381469726562,501.89813232421875],"size":[262.5184020996094,58],"flags":{},"order":6,"mode":0,"inputs":[],"outputs":[],"properties":{},"widgets_values":["Under 81 frames doesn't seem to work?"],"color":"#432","bgcolor":"#653"},{"id":36,"type":"Note","pos":[796.0189208984375,-521.5020751953125],"size":[298.2554016113281,108.62744140625],"flags":{},"order":7,"mode":0,"inputs":[],"outputs":[],"properties":{},"widgets_values":["sdpa should work too, haven't tested flaash\n\nfp8_fast seems to cause huge quality degradation"],"color":"#432","bgcolor":"#653"},{"id":21,"type":"WanVideoVAELoader","pos":[401.8250427246094,393.2132873535156],"size":[315,82],"flags":{},"order":8,"mode":0,"inputs":[],"outputs":[{"name":"vae","type":"WANVAE","links":[21,34],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoVAELoader"},"widgets_values":["Wan2_1_VAE_bf16.safetensors","bf16"]},{"id":16,"type":"WanVideoTextEncode","pos":[675.8850708007812,-36.032100677490234],"size":[400,200],"flags":{},"order":10,"mode":0,"inputs":[{"name":"t5","type":"WANTEXTENCODER","link":15}],"outputs":[{"name":"text_embeds","type":"WANVIDEOTEXTEMBEDS","links":[30],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoTextEncode"},"widgets_values":["a woman frying meat on grill","bad quality video",true]},{"id":22,"type":"WanVideoModelLoader","pos":[620.3950805664062,-357.8426818847656],"size":[477.4410095214844,226.43276977539062],"flags":{},"order":9,"mode":0,"inputs":[{"name":"compile_args","type":"WANCOMPILEARGS","link":null,"shape":7},{"name":"block_swap_args","type":"BLOCKSWAPARGS","link":39,"shape":7},{"name":"lora","type":"HYVIDLORA","link":null,"shape":7}],"outputs":[{"name":"model","type":"WANVIDEOMODEL","links":[29],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoModelLoader"},"widgets_values":["Wan2_1-I2V-14B-480P_fp8_e4m3fn.safetensors","bf16","fp8_e4m3fn","offload_device","sageattn"]},{"id":17,"type":"WanVideoImageClipEncode","pos":[875.01025390625,278.4588623046875],"size":[315,170],"flags":{},"order":11,"mode":0,"inputs":[{"name":"clip","type":"WANCLIP","link":17},{"name":"image","type":"IMAGE","link":18},{"name":"vae","type":"WANVAE","link":21}],"outputs":[{"name":"image_embeds","type":"WANVIDIMAGE_EMBEDS","links":[32],"slot_index":0}],"properties":{"Node name for S&R":"WanVideoImageClipEncode"},"widgets_values":[856,480,81,true]}],"links":[[15,11,0,16,0,"WANTEXTENCODER"],[17,13,0,17,0,"WANCLIP"],[18,18,0,17,1,"IMAGE"],[21,21,0,17,2,"VAE"],[29,22,0,27,0,"WANVIDEOMODEL"],[30,16,0,27,1,"WANVIDEOTEXTEMBEDS"],[32,17,0,27,2,"WANVIDIMAGE_EMBEDS"],[33,27,0,28,1,"LATENT"],[34,21,0,28,0,"VAE"],[36,28,0,30,0,"IMAGE"],[39,32,0,22,1,"BLOCKSWAPARGS"]],"groups":[],"config":{},"extra":{"ds":{"scale":0.8954302432552445,"offset":[67.88458120864142,670.8732745160719]},"node_versions":{"ComfyUI-WanVideoWrapper":"c83f47e4d97b5891058555df16db5e33d16afab1","comfy-core":"0.3.14","ComfyUI-VideoHelperSuite":"2c25b8b53835aaeb63f831b3137c705cf9f85dce"},"VHS_latentpreview":false,"VHS_latentpreviewrate":0,"VHS_MetadataImage":true,"VHS_KeepIntermediate":true},"version":0.4}
Additional Context
(Please add any additional context or steps to reproduce the error here)
You dont have sageattention installed. Either install it (complex on windows). Or simply change the attention type in the model loader node.
You can try following the instructions here: https://old.reddit.com/r/StableDiffusion/comments/1h7hunp/how_to_run_hunyuanvideo_on_a_single_24gb_vram_card/
does sageattention affect to quality output ? i have same error but when i switch to sdpa, it find
does sageattention affect to quality output ? i have same error but when i switch to sdpa, it find
This is the speed of attention, not the speed of the entire image output. The video has improved, and the attention effect is not good. The quality will be reduced after quantification. Otherwise, just use SDP.
does sageattention affect to quality output ? i have same error but when i switch to sdpa, it find
i have tested and found that , sageattention is too much better then sdpa on motion folowing the prompt
sadly sage still not available on mac (metal)?
I resolved the issue by running pip install sageattention, but I'm confused as to why this package isn't listed in the requirements.txt file.
I resolved the issue by running pip install sageattention, but I'm confused as to why this package isn't listed in the requirements.txt file.
Because it's fully optional, and just having the pip package installed is not enough for it to actually work, in most cases it also needs Triton and compilation setup on your system.
I resolved the issue by running pip install sageattention, but I'm confused as to why this package isn't listed in the requirements.txt file.
Which folder did you do this in?
for me, it was just
pip install -U sageattention
pip install -U triton-windows
(after closing comfy) That worked. It cut down my generation time from 17 minutes to 11 minutes.
谢谢,我也遇到了这个问题,感谢。
I have SageAttn loaded on Win11 and it works fine with the native Wan WF in Comfy and use the "Patch Sage Attention KJ" node. But on kijai's T2V WF, there is the "WanVideo Model Loader" node, which has the Model output in the color green. Can't use the "Patch Sage Attention KJ" node because the Model input is purple. They are incompatible.
What am I missing ... any help will be appreciated 👍
I have SageAttn loaded on Win11 and it works fine with the native Wan WF in Comfy and use the "Patch Sage Attention KJ" node. But on kijai's T2V WF, there is the "WanVideo Model Loader" node, which has the Model output in the color green. Can't use the "Patch Sage Attention KJ" node because the Model input is purple. They are incompatible.
What am I missing ... any help will be appreciated 👍
It's built in the model loader node, you just change attention mode, no need for any patch nodes.
I have SageAttn loaded on Win11 and it works fine with the native Wan WF in Comfy and use the "Patch Sage Attention KJ" node. But on kijai's T2V WF, there is the "WanVideo Model Loader" node, which has the Model output in the color green. Can't use the "Patch Sage Attention KJ" node because the Model input is purple. They are incompatible. What am I missing ... any help will be appreciated 👍
It's built in the model loader node, you just change attention mode, no need for any patch nodes.
Thank you Kijai !
I resolved the issue by running pip install sageattention, but I'm confused as to why this package isn't listed in the requirements.txt file.
Because it's fully optional, and just having the pip package installed is not enough for it to actually work, in most cases it also needs Triton and compilation setup on your system.
Hi @kijai , so as I have had issues with sageattention, it is installed and still it says it is not installed, if I would like to avoid the use of it how can I do it?, I got a workflow like this.
Thank you so much for your time in advance. Bruno
I resolved the issue by running pip install sageattention, but I'm confused as to why this package isn't listed in the requirements.txt file.
Because it's fully optional, and just having the pip package installed is not enough for it to actually work, in most cases it also needs Triton and compilation setup on your system.
Hi @kijai , so as I have had issues with sageattention, it is installed and still it says it is not installed, if I would like to avoid the use of it how can I do it?, I got a workflow like this.
Thank you so much for your time in advance. Bruno
Make sure to install it into correct python environment.
To not use sageattention, you simply change the attention_mode to something else, sdpa being the most basic option that doesn't need anything else, it's just a lot slower than sage. If you don't have working Triton installation, you'd also disconnect the torch.compile node:
@kijai , appreciate a lot you feedback!, something definitely I need to try! Have a great day!
How to get sage attention 2.2 to work with Wan Video Model Loader?
WARNING: Ignoring invalid distribution ~ageattention (/home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages)
Name: sageattention
Version: 2.2.0
Summary: Accurate and efficient plug-and-play low-bit attention.
Home-page: https://github.com/thu-ml/SageAttention
Author: SageAttention team
Author-email:
License: Apache 2.0 License
Location: /home/umer/projects/vector_studio/comfyui/ComfyUI/SageAttention
Editable project location: /home/umer/projects/vector_studio/comfyui/ComfyUI/SageAttention
Requires:
Required-by: ```
```terminate called after throwing an instance of 'c10::Error'
what(): CUDA error: unspecified launch failure
Compile with `TORCH_USE_CUDA_DSA` to enable device-side assertions.
Exception raised from c10_cuda_check_implementation at /pytorch/c10/cuda/CUDAException.cpp:43 (most recent call first):
frame #0: c10::Error::Error(c10::SourceLocation, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >) + 0x98 (0x7fab780f45e8 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libc10.so)
frame #1: c10::detail::torchCheckFail(char const*, char const*, unsigned int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) + 0xe0 (0x7fab780894a2 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libc10.so)
frame #2: c10::cuda::c10_cuda_check_implementation(int, char const*, char const*, int, bool) + 0x3c2 (0x7fab781d2292 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libc10_cuda.so)
frame #3: <unknown function> + 0x5d213 (0x7fab781d9213 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libc10_cuda.so)
frame #4: <unknown function> + 0x44c172 (0x7fab6ee4c172 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #5: c10::TensorImpl::~TensorImpl() + 0x9 (0x7fab780cef39 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libc10.so)
frame #6: <unknown function> + 0x7033e8 (0x7fab6f1033e8 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #7: <unknown function> + 0x703810 (0x7fab6f103810 in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
<omitting python frames>
frame #10: <unknown function> + 0x72e2ad (0x7fab6f12e2ad in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #13: dynamo_eval_custom_code + 0x1fe (0x7fab6f12d17e in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #14: <unknown function> + 0x72e1ac (0x7fab6f12e1ac in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #17: dynamo_eval_custom_code + 0x1fe (0x7fab6f12d17e in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #18: <unknown function> + 0x72e1ac (0x7fab6f12e1ac in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #21: dynamo_eval_custom_code + 0x1fe (0x7fab6f12d17e in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #22: <unknown function> + 0x72e05b (0x7fab6f12e05b in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #25: dynamo_eval_custom_code + 0x1fe (0x7fab6f12d17e in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #26: <unknown function> + 0x72e05b (0x7fab6f12e05b in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #29: dynamo_eval_custom_code + 0x1fe (0x7fab6f12d17e in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #30: <unknown function> + 0x72e05b (0x7fab6f12e05b in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #35: <unknown function> + 0x72e2ad (0x7fab6f12e2ad in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
frame #40: <unknown function> + 0x72e2ad (0x7fab6f12e2ad in /home/umer/anaconda3/envs/comfyui/lib/python3.12/site-packages/torch/lib/libtorch_python.so)
Aborted (core dumped)```
How to get sage attention 2.2 to work with Wan Video Model Loader?
When it's installed properly, it will just work, I don't know what your error is about, all I can say it is working for me.
I installed Triton & Sage a few months ago. Saw on Kijai's node it's built in. I have it selected & assume it's working.
Not sure if there's a way to validate it's working???