Skip to content

安装了brushnet最新版启动报错 #84

@kileroppo

Description

@kileroppo

Describe the bug

没法正常使用blendinpaint节点

Reproduction

Error message occurred while importing the 'ComfyUI-BrushNet' module.

Traceback (most recent call last):
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\utils\import_utils.py", line 830, in get_module
return importlib.import_module("." + module_name, self.name)
File "I:\ComfyUI-aki-v1.3\python\lib\importlib_init
.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in load_unlocked
File "", line 883, in exec_module
File "", line 241, in call_with_frames_removed
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\loaders\unet.py", line 46, in
from .lora_pipeline import LORA_WEIGHT_NAME, LORA_WEIGHT_NAME_SAFE, TEXT_ENCODER_NAME, UNET_NAME
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\loaders\lora_pipeline.py", line 33, in
from .lora_base import LoraBaseMixin
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\loaders\lora_base.py", line 47, in
from peft.tuners.tuners_utils import BaseTunerLayer
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\peft_init
.py", line 17, in
from .auto import (
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\peft\auto.py", line 31, in
from .config import PeftConfig
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\peft\config.py", line 24, in
from .utils import CONFIG_NAME, PeftType, TaskType
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\peft\utils_init
.py", line 16, in
from .loftq_utils import replace_lora_weights_loftq
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\peft\utils\loftq_utils.py", line 25, in
from accelerate.utils.memory import clear_device_cache
ImportError: cannot import name 'clear_device_cache' from 'accelerate.utils.memory' (I:\ComfyUI-aki-v1.3\python\lib\site-packages\accelerate\utils\memory.py)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "I:\ComfyUI-aki-v1.3\nodes.py", line 2153, in load_custom_node
module_spec.loader.exec_module(module)
File "", line 883, in exec_module
File "", line 241, in call_with_frames_removed
File "I:\ComfyUI-aki-v1.3\custom_nodes\comfyui-brushnet_init
.py", line 1, in
from .brushnet_nodes import BrushNetLoader, BrushNet, BlendInpaint, PowerPaintCLIPLoader, PowerPaint, CutForInpaint
File "I:\ComfyUI-aki-v1.3\custom_nodes\comfyui-brushnet\brushnet_nodes.py", line 15, in
from .brushnet.brushnet import BrushNetModel
File "I:\ComfyUI-aki-v1.3\custom_nodes\comfyui-brushnet\brushnet\brushnet.py", line 20, in
from .unet_2d_blocks import (
File "I:\ComfyUI-aki-v1.3\custom_nodes\comfyui-brushnet\brushnet\unet_2d_blocks.py", line 36, in
from diffusers.models.transformers.dual_transformer_2d import DualTransformer2DModel
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\models\transformers_init_.py", line 13, in
from .prior_transformer import PriorTransformer
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\models\transformers\prior_transformer.py", line 9, in
from ...loaders import PeftAdapterMixin, UNet2DConditionLoadersMixin
File "", line 1075, in _handle_fromlist
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\utils\import_utils.py", line 820, in getattr
module = self._get_module(self._class_to_module[name])
File "I:\ComfyUI-aki-v1.3\python\lib\site-packages\diffusers\utils\import_utils.py", line 832, in _get_module
raise RuntimeError(
RuntimeError: Failed to import diffusers.loaders.unet because of the following error (look up to see its traceback):
cannot import name 'clear_device_cache' from 'accelerate.utils.memory' (I:\ComfyUI-aki-v1.3\python\lib\site-packages\accelerate\utils\memory.py)

Logs

System Info

diffusers:v0.33 python:3.10

Who can help?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions