404 Client Error: Not Found for url: https://huggingface.co/api/models/openai/whisper-base (Request ID: Root=1-645a4e29-340f73241a7dbe9f3a6458ac)

#42
by liushaowei - opened

from transformers import WhisperTokenizer, pipeline, WhisperFeatureExtractor
from transformers import WhisperProcessor, WhisperForConditionalGeneration

model_path = "openai/whisper-base"

pipe = pipeline(model=model_path)
def transcribe(audio):
text = pipe(audio)["text"]
return text
print(transcribe("./source_audio/0swbrzwmwdq.aac"))

I just use above code to load model, but i get error, how can i resolve it
Traceback (most recent call last):
File "/home/liushaowei/.local/lib/python3.10/site-packages/transformers/pipelines/init.py", line 423, in get_task
info = model_info(model, token=use_auth_token)
File "/home/liushaowei/.local/lib/python3.10/site-packages/huggingface_hub/utils/_validators.py", line 120, in _inner_fn
return fn(*args, **kwargs)
File "/home/liushaowei/.local/lib/python3.10/site-packages/huggingface_hub/hf_api.py", line 1624, in model_info
hf_raise_for_status(r)
File "/home/liushaowei/.local/lib/python3.10/site-packages/huggingface_hub/utils/_errors.py", line 301, in hf_raise_for_status
raise HfHubHTTPError(str(e), response=response) from e
huggingface_hub.utils._errors.HfHubHTTPError: 404 Client Error: Not Found for url: https://huggingface.co/api/models/openai/whisper-base (Request ID: Root=1-645a4e29-340f73241a7dbe9f3a6458ac)

Sorry, we can't find the page you are looking for.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/liushaowei/VscodeWork/PythonWork/video-to-text/usePretrainModel.py", line 141, in
pipe = pipeline(model=model_path, chunk_length_s=30)
File "/home/liushaowei/.local/lib/python3.10/site-packages/transformers/pipelines/init.py", line 716, in pipeline
task = get_task(model, use_auth_token)
File "/home/liushaowei/.local/lib/python3.10/site-packages/transformers/pipelines/init.py", line 425, in get_task
raise RuntimeError(f"Instantiating a pipeline without a task set raised an error: {e}")
RuntimeError: Instantiating a pipeline without a task set raised an error: 404 Client Error: Not Found for url: https://huggingface.co/api/models/openai/whisper-base (Request ID: Root=1-645a4e29-340f73241a7dbe9f3a6458ac)

Sorry, we can't find the page you are looking for.

Sign up or log in to comment