当前位置: 首页 > news >正文

ComfyUI模型下载与路径问题解决

1.路径报错信息一

got prompt
model_path is D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\ckpts\hr16\Diffusion-Edge\diffusion_edge_indoor.pt
making attention of type 'vanilla' with 512 in_channels
Working with z of shape (1, 3, 80, 80) = 19200 dimensions.
making attention of type 'vanilla' with 512 in_channels
Failed to find C:\Users\彭林/.cache\torch\hub\checkpoints\vgg16-397923af.pth.
 Downloading from pytorch.org
model_path is D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\ckpts\torch\vgg16-397923af.pth
loaded pretrained LPIPS loss from taming/modules/autoencoder/lpips\vgg.pth
Failed to find C:\Users\彭林/.cache\torch\hub\checkpoints\swin_b-68c6b09e.pth.
 Downloading from pytorch.org
model_path is D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\ckpts\torch\swin_b-68c6b09e.pth
!!! Exception during processing !!! PytorchStreamReader failed reading zip archive: failed finding central directory
Traceback (most recent call last):
  File "D:\AI\ComfyUI_windows\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:\AI\ComfyUI_windows\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:\AI\ComfyUI_windows\ComfyUI\execution.py", line 174, in _map_node_over_list
    process_inputs(input_dict, i)
  File "D:\AI\ComfyUI_windows\ComfyUI\execution.py", line 163, in process_inputs
    results.append(getattr(obj, func)(**inputs))
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\node_wrappers\diffusion_edge.py", line 30, in execute
    .from_pretrained(filename = f"diffusion_edge_{environment}.pt") \
     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\src\custom_controlnet_aux\diffusion_edge\__init__.py", line 16, in from_pretrained
    model = DiffusionEdge(prepare_args(model_path))
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\src\custom_controlnet_aux\diffusion_edge\model.py", line 44, in __init__
    unet = Unet(dim=unet_cfg.dim,
           ^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\src\custom_controlnet_aux\diffusion_edge\denoising_diffusion_pytorch\mask_cond_unet.py", line 703, in __init__
    swin_b_model.load_state_dict(torch.load(custom_torch_download(filename="swin_b-68c6b09e.pth")), strict=False)
                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\python_embeded\Lib\site-packages\torch\serialization.py", line 1432, in load
    with _open_zipfile_reader(opened_file) as opened_zipfile:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\AI\ComfyUI_windows\python_embeded\Lib\site-packages\torch\serialization.py", line 763, in __init__
    super().__init__(torch._C.PyTorchFileReader(name_or_buffer))
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: PytorchStreamReader failed reading zip archive: failed finding central directory

Deepseek解决方案

The error occurs because the swin_b-68c6b09e.pth model file is either missing, incomplete, or corrupted. Here’s how to resolve it:

Manually Download the Model:

Visit the official PyTorch URL: https://download.pytorch.org/models/swin_b-68c6b09e.pth

Ensure the download completes fully (~440MB).

Place the Model Correctly:

Save the downloaded file to:

复制
D:\AI\ComfyUI_windows\ComfyUI\custom_nodes\comfyui_controlnet_aux\ckpts\torch\swin_b-68c6b09e.pth
1.Replace any existing corrupted/incomplete file.

2.Verify File Integrity:

3.Check the file size matches the expected size (~440MB).

If using a browser download, retry if interrupted.

4.Update Custom Nodes:

5.Ensure comfyui_controlnet_aux is up-to-date in case of bugs in model handling.

6.After fixing, the error should resolve as the model loads correctly. If issues persist, check file permissions or reinstall the custom node.

综上所述解决方法:

删掉230MB,重新下载440MB的解决

2.路径报错信息二

Updating: ComfyUI_MatAnyone_Kytra
[ComfyUI-Manager] Queued works are completed.
{
   'update-comfyui': 1, 'update-main': 18}

After restarting ComfyUI, please refresh the browser.
got prompt
D:\AI\ComfyUI_windows\python_embeded\Lib\site-packages\albumentations\__init__.py:13: UserWarning: A new version of Albumentations is available: 2.0.5 (you have 1.4.15). Upgrade using: pip install -U albumentations. To disable automatic update checks, set the environment variable NO_ALBUMENTATIONS_UPDATE to 1.
  check_for_updates()
D:\AI\ComfyUI_windows\python_embeded\Lib\site-packages\torch\functional

相关文章:

  • IAGCN:登上《Nature》的深度学习可解释性情感分析模型突破
  • Appium的学习总结-Inspector参数设置和界面使用(5)
  • 【图像处理基石】什么是ISP色彩管理?
  • Android OpenCV 人脸识别 识别人脸框 识别人脸控件自定义
  • python小整数池和字符串贮存
  • Threejs实现天空盒效果
  • 前端单页应用性能优化全指南:从加载提速到极致体验
  • 《AI大模型趣味实战》智能财务助手系统配套说明:数据报表与指标手册
  • flink cdc的source数据流如何配置事件时间,如何设置时间语义,分配时间戳并生成水位线
  • JavaScript-异步和同步函数使用场景及区别-正确构建程序的核心要点
  • 3️⃣ Coze工作流基础教学(2025年全新版本)
  • 学习MySQL第七天
  • 使用Pholcus编写Go爬虫示例
  • 高数 | 用简单的话讲考研数学知识点(二重积分)
  • 是德科技KEYSIGHT校准件85039B
  • Kubernetes 集群搭建(二):搭建k8s集群 (1.28版本)
  • rustdesk折腾手记
  • Git 仓库在内网与 Gitee 间迁移及同步记录
  • 2025年客运从业资格证考试真题分享
  • laravel update报In PackageManifest.php line 122:Undefined index: name 错误的解决办法
  • 网站建设 步骤/海外市场推广策略
  • 河池市民政局门户网站建设/百度竞价平台官网
  • 一是加强了网站建设/成都最新消息今天
  • 免费在线建站/市场调研报告怎么写
  • 资源共享课程网站开发毕业设计/一键免费建站
  • 万州电商网站建设/媒体发稿费用