UnicomAI / Unichat-llama3-Chinese

Apache License 2.0
340 stars 34 forks source link

这个出错怎样解决 #6

Open ssaver1973 opened 4 months ago

ssaver1973 commented 4 months ago

root@autodl-container-a2d545ac4b-d5cf7770:~/autodl-tmp# python inference.py Traceback (most recent call last): File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_errors.py", line 304, in hf_raise_for_status response.raise_for_status() File "/root/miniconda3/lib/python3.8/site-packages/requests/models.py", line 1021, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://huggingface.co/UnicomAI/Unichat-llama3-Chinese/resolve/main/config.json

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

Traceback (most recent call last): File "/root/miniconda3/lib/python3.8/site-packages/transformers/utils/hub.py", line 385, in cached_file resolved_file = hf_hub_download( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_validators.py", line 119, in _inner_fn return fn(*args, *kwargs) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1403, in hf_hub_download raise head_call_error File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1261, in hf_hub_download metadata = get_hf_file_metadata( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_validators.py", line 119, in _inner_fn return fn(args, **kwargs) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1674, in get_hf_file_metadata r = _request_wrapper( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 369, in _request_wrapper response = _request_wrapper( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 393, in _request_wrapper hf_raise_for_status(response) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_errors.py", line 352, in hf_raise_for_status raise RepositoryNotFoundError(message, response) from e huggingface_hub.utils._errors.RepositoryNotFoundError: 401 Client Error. (Request ID: Root=1-66293061-5ee395d97bfd14416b40ecd6;a109ba4e-869f-492e-86ad-1d80fa547bc4)

Repository Not Found for url: https://huggingface.co/UnicomAI/Unichat-llama3-Chinese/resolve/main/config.json. Please make sure you specified the correct repo_id and repo_type. If you are trying to access a private or gated repo, make sure you are authenticated. Invalid username or password.

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

Traceback (most recent call last): File "inference.py", line 7, in pipeline = transformers.pipeline( File "/root/miniconda3/lib/python3.8/site-packages/transformers/pipelines/init.py", line 747, in pipeline resolved_config_file = cached_file( File "/root/miniconda3/lib/python3.8/site-packages/transformers/utils/hub.py", line 406, in cached_file raise EnvironmentError( OSError: UnicomAI/Unichat-llama3-Chinese is not a local folder and is not a valid model identifier listed on 'https://huggingface.co/models' If this is a private repository, make sure to pass a token having permission to this repo either by logging in with huggingface-cli login or by passing token=<your_token>

LiangYong1216 commented 4 months ago

你没有授权!!!!

UnicomAI commented 4 months ago

root@autodl-container-a2d545ac4b-d5cf7770:~/autodl-tmp# python inference.py Traceback (most recent call last): File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_errors.py", line 304, in hf_raise_for_status response.raise_for_status() File "/root/miniconda3/lib/python3.8/site-packages/requests/models.py", line 1021, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://huggingface.co/UnicomAI/Unichat-llama3-Chinese/resolve/main/config.json

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

Traceback (most recent call last): File "/root/miniconda3/lib/python3.8/site-packages/transformers/utils/hub.py", line 385, in cached_file resolved_file = hf_hub_download( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_validators.py", line 119, in _inner_fn return fn(*args, *kwargs) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1403, in hf_hub_download raise head_call_error File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1261, in hf_hub_download metadata = get_hf_file_metadata( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_validators.py", line 119, in _inner_fn return fn(args, **kwargs) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 1674, in get_hf_file_metadata r = _request_wrapper( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 369, in _request_wrapper response = _request_wrapper( File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/file_download.py", line 393, in _request_wrapper hf_raise_for_status(response) File "/root/miniconda3/lib/python3.8/site-packages/huggingface_hub/utils/_errors.py", line 352, in hf_raise_for_status raise RepositoryNotFoundError(message, response) from e huggingface_hub.utils._errors.RepositoryNotFoundError: 401 Client Error. (Request ID: Root=1-66293061-5ee395d97bfd14416b40ecd6;a109ba4e-869f-492e-86ad-1d80fa547bc4)

Repository Not Found for url: https://huggingface.co/UnicomAI/Unichat-llama3-Chinese/resolve/main/config.json. Please make sure you specified the correct repo_id and repo_type. If you are trying to access a private or gated repo, make sure you are authenticated. Invalid username or password.

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

Traceback (most recent call last): File "inference.py", line 7, in pipeline = transformers.pipeline( File "/root/miniconda3/lib/python3.8/site-packages/transformers/pipelines/init.py", line 747, in pipeline resolved_config_file = cached_file( File "/root/miniconda3/lib/python3.8/site-packages/transformers/utils/hub.py", line 406, in cached_file raise EnvironmentError( OSError: UnicomAI/Unichat-llama3-Chinese is not a local folder and is not a valid model identifier listed on 'https://huggingface.co/models' If this is a private repository, make sure to pass a token having permission to this repo either by logging in with huggingface-cli login or by passing token=<your_token>

用魔搭或始智