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

报错,我用脚本下载的model,位置和目录结构都正确,但是还是报错 #1

Open
caissonfiv opened this issue Mar 7, 2024 · 7 comments

Comments

@caissonfiv
Copy link

Error occurred when executing AnimateAnyone:

We couldn't connect to 'https://huggingface.co' to load this model, couldn't find it in the cached files and it looks like models/animate_anyone/controlnet is not the path to a directory containing a config.json file.
Checkout your internet connection or see how to run the library in offline mode at 'https://huggingface.co/docs/diffusers/installation#offline-mode'.

File "E:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 152, in recursive_execute
output_data, output_ui = get_output_data(obj, input_data_all)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 82, in get_output_data
return_values = map_node_over_list(obj, input_data_all, obj.FUNCTION, allow_interrupt=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\ComfyUI\execution.py", line 75, in map_node_over_list
results.append(getattr(obj, func)(**slice_dict(input_data_all, i)))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\ComfyUI\custom_nodes\ComfyUI-AnimateAnyone-reproduction\animate_anyone_nodes.py", line 106, in run_inference
controlnet = ControlNetSDVModel.from_pretrained(args["pretrained_model_name_or_path"] + "/controlnet")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\python_embeded\Lib\site-packages\huggingface_hub\utils_validators.py", line 118, in _inner_fn
return fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\python_embeded\Lib\site-packages\diffusers\models\modeling_utils.py", line 712, in from_pretrained
config, unused_kwargs, commit_hash = cls.load_config(
^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\python_embeded\Lib\site-packages\huggingface_hub\utils_validators.py", line 118, in _inner_fn
return fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^
File "E:\AI\ComfyUI_windows_portable\python_embeded\Lib\site-packages\diffusers\configuration_utils.py", line 411, in load_config
raise EnvironmentError(

@Lex974
Copy link

Lex974 commented Mar 7, 2024

I was the same, i fix it by put the checkpoint in the right folder did you check the folder correctly and download all models ?

@caissonfiv
Copy link
Author

I was the same, i fix it by put the checkpoint in the right folder did you check the folder correctly and download all models ?

I use prepare.py download , How exactly did you fix it?

@Lex974
Copy link

Lex974 commented Mar 8, 2024

I use the first method

@nomadoor
Copy link

nomadoor commented Mar 8, 2024

I also encountered the same error, and even after a manual installation, the error persisted.

Then, when I changed the path to the model within animate_anyone_nodes.py to a full path, it worked, though I’m not exactly sure why.

Line 95 of animate_anyone_nodes.py

args = {
-    "pretrained_model_name_or_path": "models/animate_anyone",
+    "pretrained_model_name_or_path": "D:/AI/ComfyUI_windows_portable/ComfyUI/models/animate_anyone",
}

@caissonfiv
Copy link
Author

though

OK!I'll try it.

@caissonfiv
Copy link
Author

I also encountered the same error, and even after a manual installation, the error persisted.

Then, when I changed the path to the model within animate_anyone_nodes.py to a full path, it worked, though I’m not exactly sure why.

Line 95 of animate_anyone_nodes.py

args = {

-    "pretrained_model_name_or_path": "models/animate_anyone",

+    "pretrained_model_name_or_path": "D:/AI/ComfyUI_windows_portable/ComfyUI/models/animate_anyone",

}

Run successfully,Thank you!

@nomadoor
Copy link

That’s great!
But why doesn’t it work well with a relative path?🤔

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

No branches or pull requests

3 participants