Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why do I have to download again every time I run it? #39

Closed
Yorha4D opened this issue Sep 9, 2023 · 9 comments · Fixed by #96
Closed

Why do I have to download again every time I run it? #39

Yorha4D opened this issue Sep 9, 2023 · 9 comments · Fixed by #96

Comments

@Yorha4D
Copy link

Yorha4D commented Sep 9, 2023

I want to use local files instead of downloading them from Hugface every time. And after downloading hugface, it will be downloaded again. I don't understand why it is necessary to download so many duplicate models @Fannovel16

@green-anger
Copy link

I've tried this only once, so don't know if it downloads models every time. However, it saved it inside directory "ckpts/.../snapshots/..." which is deeply nested inside the node path and inside snapshots it created a directory with long random name. This is extremely inconvenient. Would be perfect if we could set a path to all models, similar to how we redirect comfy to a1111's model paths. The node doesn't seem to have a settings file and there's no mentioning of such settings in the readme.md.

@Yorha4D
Copy link
Author

Yorha4D commented Sep 10, 2023

@green-anger This random code may be related to the network address (my home and company are not the same), and I have changed the code myself so that it can be used even without the network.
#29 (comment)
image

@hanli2016
Copy link

@green-anger This random code may be related to the network address (my home and company are not the same), and I have changed the code myself so that it can be used even without the network. #29 (comment) image

It work for me,Thanke you!

@youcanyoubing
Copy link

这个随机代码可能与网络地址有关(我家和公司不一样),我自己更改了代码,以便即使没有网络也可以使用。 #29(评论) image

你好,如何使用本地的模型,我完全连不上拥抱脸了,只有之前下载的模型

@Fannovel16
Copy link
Owner

I think I should replace huggingface_hub with direct downloading 🤔. That library isn't compatible with all enviroments. But such change will require redownloading.

@donglsci
Copy link

However, it saved it inside directory "ckpts/.../snapshots/..." @green-anger

thanks a lot, i copied these five files to that directory, happy to find them works well, and do not need to download them again.
(i also tried to put these files to the path of lllyasviel/Annotators and yzd-v/DWPose, but it did not worked, maybe due to the version difference. )

000

@suede299
Copy link

Still wish there was a version that could use local models.
I created a new folder like I said above and copied the 2 models from DWpose over, but it still connects to Hugface.
It's definitely not going to download every time, but it must be trying to access Hugface, doing version comparisons and whatnot. It takes many seconds before it starts processing, as it does very quickly when I have vpn on.

Translated with www.DeepL.com/Translator

@Yorha4D
Copy link
Author

Yorha4D commented Sep 28, 2023

@youcanyoubing @donglsci @suede299 Based on the information I have collected, there are currently more than 20 countries that are unable to connect directly or at low speeds (<10kb). So for people in these countries, connecting to huggingface to download several gigabytes of files is 100% error reporting. Here is a local version that can be used。https://github.com/DorotaLuna/comfyui_controlnet_aux_stable

@Layer-norm
Copy link
Contributor

@Yorha4D I've changed all functions used hf_hub_download. It won't downlod models again. Besides, if the dir already existent while models not, it won't cause load error any more. You can use my repo with git clone -b download https://github.com/Layer-norm/comfyui_controlnet_aux.git
Here are the log and workflow.
log
test

Fannovel16 added a commit that referenced this issue Nov 5, 2023
Change download functions and fix download error (#39)
Foligattilj added a commit to Foligattilj/comfyui_controlnet_aux that referenced this issue Jul 24, 2024
Change download functions and fix download error (Fannovel16/comfyui_controlnet_aux#39)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants