DeepSpeech/native_client/client.py
Chris Lord 616d77ef2d Various renames in libdeepspeech to allow for clearer more efficient use
libdeepspeech now uses the namespace DeepSpeech. The 'DeepSpeech' class
has been renamed to 'Model', 'getMfccFrames' has been renamed to
'getInputVector' and a function outside of the Model class has been added,
'audioToInputVector' to allow it to be used without initialising
TensorFlow and loading a model.
2017-05-17 10:52:14 +01:00

8 lines
161 B
Python

import sys
import scipy.io.wavfile as wav
from deepspeech import Model
ds = Model(sys.argv[1], 26, 9)
fs, audio = wav.read(sys.argv[2])
print ds.stt(audio, fs)