Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 460858f

Browse filesBrowse files
gguussJon Wayne Parrott
authored andcommitted
Speech version bump [(#899)](GoogleCloudPlatform/python-docs-samples#899)
* Changes docs for async playback to point to LINEAR16 example * Updates to client library with FLAC support. * Changes async examples to flac and updates README
1 parent 285b482 commit 460858f
Copy full SHA for 460858f

File tree

Expand file treeCollapse file tree

3 files changed

+4
-4
lines changed
Filter options
Expand file treeCollapse file tree

3 files changed

+4
-4
lines changed

‎samples/snippets/requirements.txt

Copy file name to clipboard
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
google-cloud-speech==0.25.0
1+
google-cloud-speech==0.25.1

‎samples/snippets/transcribe_async.py

Copy file name to clipboardExpand all lines: samples/snippets/transcribe_async.py
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
2020
Example usage:
2121
python transcribe_async.py resources/audio.raw
22-
python transcribe_async.py gs://cloud-samples-tests/speech/brooklyn.raw
22+
python transcribe_async.py gs://cloud-samples-tests/speech/brooklyn.flac
2323
"""
2424

2525
import argparse
@@ -67,7 +67,7 @@ def transcribe_gcs(gcs_uri):
6767
audio_sample = speech_client.sample(
6868
content=None,
6969
source_uri=gcs_uri,
70-
encoding='LINEAR16',
70+
encoding='FLAC',
7171
sample_rate_hertz=16000)
7272

7373
operation = audio_sample.long_running_recognize('en-US')

‎samples/snippets/transcribe_async_test.py

Copy file name to clipboardExpand all lines: samples/snippets/transcribe_async_test.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def test_transcribe(capsys):
2929

3030
def test_transcribe_gcs(capsys):
3131
transcribe_async.transcribe_gcs(
32-
'gs://python-docs-samples-tests/speech/audio.raw')
32+
'gs://python-docs-samples-tests/speech/audio.flac')
3333
out, err = capsys.readouterr()
3434

3535
assert re.search(r'how old is the Brooklyn Bridge', out, re.DOTALL | re.I)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.