Automatic Speech Recognition
Transformers
PyTorch
TensorFlow
JAX
Safetensors
whisper
audio
hf-asr-leaderboard
Eval Results (legacy)
Instructions to use openai/whisper-tiny with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use openai/whisper-tiny with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="openai/whisper-tiny")# Load model directly from transformers import AutoProcessor, AutoModelForSpeechSeq2Seq processor = AutoProcessor.from_pretrained("openai/whisper-tiny") model = AutoModelForSpeechSeq2Seq.from_pretrained("openai/whisper-tiny") - Notebooks
- Google Colab
- Kaggle
Is there a tutorial on how to use this?
#8
by thuangster - opened
Apologize for the dumb question. I am new to hugging face and sagemaker.
I wanted to deploy whisper model on sagemaker, that worked. But how do I get audio from s3 to actually do a prediction? Is there a tutorial I can follow to learn how to do this?
I tried the following:
import boto3
bucket = 'th-whisper-demo'
subfolder = ''
my_file = 'audio.mp3'
s3client = boto3.client('s3')
response = s3client.get_object(Bucket=bucket, Key=my_file)
body = response['Body']
predictor.predict({
'inputs': body
})
But this gives me an error.
Any help will be appreciated.
Hey @thuangster ! What's the error message that you receive?