Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mlapis.ipynb speech-to-text doesn't work #432

Open
wbwvos opened this issue Apr 8, 2019 · 0 comments
Open

mlapis.ipynb speech-to-text doesn't work #432

wbwvos opened this issue Apr 8, 2019 · 0 comments

Comments

@wbwvos
Copy link

wbwvos commented Apr 8, 2019

The speech-to-text cell doesn't work with the v1beta1 version. Also the the parameters in the config have changed. I adapted the code as shown below, this works for me.

sservice = build('speech', 'v1', developerKey=APIKEY)
response = sservice.speech().recognize(
    body={
        'config': {
            'encoding': 'LINEAR16',
            'sample_rate_hertz': 16000,
            'language_code':'en-US'
        },
        'audio': {
            'uri': 'gs://cloud-training-demos/vision/audio.raw'
            }
        }).execute()
print(response)

Please change for a more smooth experience while doing the training.

Thanks in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant