ComfyUI-Manager icon indicating copy to clipboard operation
ComfyUI-Manager copied to clipboard

Model Install Path

Open choseokheeee opened this issue 2 years ago • 11 comments

I set the model path to a custom path by changing the extra_model_paths.yaml

comfyui:
     base_path: /custom/path/
     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/

But when I install models using the Manager, the model is installed in the ComfyUI folder(where the main.py file exists), not the custom path i set

This still works(?), but I want to change the default installation path to a custom path

choseokheeee avatar May 17 '24 05:05 choseokheeee

This is expected, @choseokheeee .

ComfyUI defines the main model folder to be ./models/, and can load extra models from extra_model_paths.

I'm not sure if it is appropriate for Manager to download models to a custom folder instead of to the main model folder.

liusida avatar May 29 '24 07:05 liusida

I set the model path to a custom path by changing the extra_model_paths.yaml

comfyui:
     base_path: /custom/path/
     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/

But when I install models using the Manager, the model is installed in the ComfyUI folder(where the main.py file exists), not the custom path i set

This still works(?), but I want to change the default installation path to a custom path

  1. Find the extra-model-paths.yaml File:

This file is typically located in the same directory as your main.py file (the main ComfyUI script). 2. Modify the base_path:

Open the extra-model-paths.yaml file in a text editor.

Change the base_path entry to your desired custom path:

YAML comfyui: base_path: /your/custom/path/ # ... (rest of the file) Use code with caution. content_copy 3. Restart ComfyUI:

Close ComfyUI if it's running. Restart it, and hopefully, ComfyUI-Manager will now install models in your custom path! Why This Might Work:

Some versions of ComfyUI-Manager might check the base_path in extra-model-paths.yaml to determine the installation location. However, this behavior is not officially documented and might not work in all cases.

Important Note:

If this doesn't work, the environment variable method (COMFYUI_MODELS_PATH) or the configuration file method (if available) are more reliable ways to change the installation path.

Amit30swgoh avatar May 31 '24 09:05 Amit30swgoh

I set the model path to a custom path by changing the extra_model_paths.yaml

comfyui:
     base_path: /custom/path/
     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/

But when I install models using the Manager, the model is installed in the ComfyUI folder(where the main.py file exists), not the custom path i set

This still works(?), but I want to change the default installation path to a custom path

another workaround is to use docker, which can mount your directory as /ComfyUI/models to replace the old one. or on Linux, delete the /ComfyUI/models and make a symbol link using ln -s <your folder> <models in Comfy>.

liusida avatar May 31 '24 10:05 liusida

I set the model path to a custom path by changing the extra_model_paths.yaml

comfyui:
     base_path: /custom/path/
     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/

But when I install models using the Manager, the model is installed in the ComfyUI folder(where the main.py file exists), not the custom path i set This still works(?), but I want to change the default installation path to a custom path

  1. Find the extra-model-paths.yaml File:

This file is typically located in the same directory as your main.py file (the main ComfyUI script). 2. Modify the base_path:

Open the extra-model-paths.yaml file in a text editor.

Change the base_path entry to your desired custom path:

YAML comfyui: base_path: /your/custom/path/ # ... (rest of the file) Use code with caution. content_copy 3. Restart ComfyUI:

Close ComfyUI if it's running. Restart it, and hopefully, ComfyUI-Manager will now install models in your custom path! Why This Might Work:

Some versions of ComfyUI-Manager might check the base_path in extra-model-paths.yaml to determine the installation location. However, this behavior is not officially documented and might not work in all cases.

Important Note:

If this doesn't work, the environment variable method (COMFYUI_MODELS_PATH) or the configuration file method (if available) are more reliable ways to change the installation path.

Is this produced by some LLMs? I feel like there's hallucination all over the place.

liusida avatar May 31 '24 14:05 liusida

I think it would be great if you could choose for each download between the local folder and the custom one (extra_model_paths).

simonknittel avatar Aug 06 '24 04:08 simonknittel

I'll handle this after CNR update is completed.

ltdrdata avatar Aug 06 '24 09:08 ltdrdata

any update on this?

devwearsprada avatar Oct 27 '24 21:10 devwearsprada

This feature will be implemented on new branch.

ltdrdata avatar Oct 29 '24 17:10 ltdrdata

any update ?

executorrr86 avatar Dec 20 '24 12:12 executorrr86

any update ?

This is updated already.

You can use like this.

    some_extra_path:
       base_path: /path/to/base
       download_model_base: models
       checkpoints: models/checkpoints
       text_encoders: models/text_encoders
       vae: models/vae
       loras: models/loras
       controlnet: models/controlnet
       clip_vision: models/clip_vision
       gligen: models/gligen
       upscale_models: models/upscale_models
       embeddings: models/embeddings
       diffusion_models: models/diffusion_models
       custom_nodes: custom_nodes
       is_default: True

download_model_base is important.

ltdrdata avatar Dec 20 '24 13:12 ltdrdata

Take note of the path to the ComfyUI folder, which contains the models and outputs folders. Guide for Windows

Open the Environment Variables Settings:
    Press Win + R to open the Run dialog.
    Type SystemPropertiesAdvanced and press Enter.
    Click the Environment Variables button in the Advanced tab. 

Add the Environment Variable:
    In the System Variables section (or User Variables if you prefer setting it for the current user), click New.
    For Variable Name, enter COMFYUI_DIR.
    For Variable Value, enter the full path to your ComfyUI folder (e.g., C:\path\to\ComfyUI). 

Save and Apply:
    Click OK to save.
    Close all dialogs by clicking OK. 

Verify:
    Open Command Prompt (Win + R, type cmd, and press Enter).
    Run echo %COMFYUI_DIR%.
    It should display the path to your ComfyUI folder. 

tomaszwalczak2809-star avatar Mar 15 '26 22:03 tomaszwalczak2809-star