Skip to content

Instantly share code, notes, and snippets.

@ranman
Created December 12, 2017 09:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save ranman/be87288af3bb8ee8e8490c4ba49dae32 to your computer and use it in GitHub Desktop.
Save ranman/be87288af3bb8ee8e8490c4ba49dae32 to your computer and use it in GitHub Desktop.
import time
import boto3
transcribe = boto3.client('transcribe')
transcribe.start_transcription_job(
TranscriptionJobName='RandallTest1',
Media={
'MediaFileUri': 'https://s3-us-west-2.amazonaws.com/randhunt-transcribe-demos/test.flac'
},
MediaFormat='flac',
LanguageCode='en-US',
MediaSampleRateHertz=44100
)
while transcribe.get_transcription_job(TranscriptionJobName="RandallTest1")['TranscriptionJob']['TranscriptionJobStatus'] !=
"COMPLETED":
print("Not Ready Yet...")
time.sleep(5)
print(transcribe.get_transcription_job(TranscriptionJobName="RandallTest1"))
@ahmed-abdelazim
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment