comfyanonymous / ComfyUI

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface.
https://www.comfy.org/
GNU General Public License v3.0
52.47k stars 5.54k forks source link

Sharing custom_nodes, clip_vision and other models folders #3143

Open nothingness6 opened 6 months ago

nothingness6 commented 6 months ago

I'm using 2 ComfyUIs. One with Stability Matrix and another one with just portable version. I could manage the models that are used in Automatic1111, and they work fine, which means, #config for a1111 ui, works fine. But the ComfyUI models such as custom_nodes, clip_vision and other models (eg: animatediff_models, facerestore_models, insightface and sams) are not sharable, which means, #config for comfyui, seems not working. I modified the extra_model_paths.yaml file as below:

#Rename this to extra_model_paths.yaml and ComfyUI will load it

#config for a1111 ui
#all you have to do is change the base_path to where yours is installed
a111:
    base_path: M:\AI_Tools\StabilityMatrix-win-x64\Data\Packages\stable-diffusion-webui\

    checkpoints: models/Stable-diffusion
    configs: models/Stable-diffusion
    vae: models/VAE
    loras: |
         models/Lora
         models/LyCORIS
    upscale_models: |
                  models/ESRGAN
                  models/RealESRGAN
                  models/SwinIR
    embeddings: embeddings
    hypernetworks: models/hypernetworks
    controlnet: models/ControlNet

#config for comfyui
#your base path should be either an existing comfy install or a central folder where you store all of your models, loras, etc.

#comfyui:
#     base_path: M:\AI_Tools\StabilityMatrix-win-x64\Data\Packages\ComfyUI
#     checkpoints: models/checkpoints/
#     clip: models/clip/
#     clip_vision: models/clip_vision/
#     configs: models/configs/
#     controlnet: models/controlnet/
#     embeddings: models/embeddings/
#     loras: models/loras/
#     upscale_models: models/upscale_models/
#     vae: models/vae/
#     animatediff_motion_lora: M:\AI_Tools\StabilityMatrix-win-x64\Data\Packages\ComfyUI\models\animatediff_motion_lora\
#     animatediff_models: M:\AI_Tools\StabilityMatrix-win-x64\Data\Packages\ComfyUI\models\animatediff_models\

#other_ui:
#    base_path: path/to/ui
#    checkpoints: models/checkpoints
#    gligen: models/gligen
#    custom_nodes: path/custom_nodes

But it doesn't work as I thought. How do I make them sharable?

Ruszero01 commented 6 months ago

need "/"

nothingness6 commented 6 months ago

need "/"

Seriously? Then how could the Stable-Diffusion path work?

Ruszero01 commented 6 months ago

image that'll make it work, maybe M:/AI_Tools/StabilityMatrix-win-x64/Data/Packages/stable-diffusion-webui

Ruszero01 commented 6 months ago

image Also, if you want the code to work, you need to remove the "#" in front of it, which is meant to be a comment, meaning that this line will not run in the code

nothingness6 commented 6 months ago

image that'll make it work, maybe M:/AI_Tools/StabilityMatrix-win-x64/Data/Packages/stable-diffusion-webui

I mean, it works without fixing like this. but only ComfyUI setting doesn't work. That's why I asked. My point is that why A works, but B doesn't work under the same circumstances.

Ruszero01 commented 5 months ago

image If B means this, you need to delete the previous comment symbol and comment out All rows in A image