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?

Sign up or log in to comment