sphinx
import os from pocketsphinx import LiveSpeech, get_model_path model_path = get_model_path() speech = LiveSpeech( verbose=False, sampling_rate=16000, buffer_size=2048, no_search=False, full_utt=False, hmm=os.path.join(model_path, 'zh_cn.cd_cont_5000'), lm=os.path.join(model_path, 'zh_cn.lm.bin'), dic=os.path.join(model_path, 'zh_cn.dic') ) for phrase in speech: print("phrase:", phrase) print(phrase.segments(detailed=True))
https://github.com/cmusphinx/pocketsphinx-python
deps/sphinxbase/src/libsphinxad/ad_alsa.c:76:10: fatal error: alsa/asoundlib.h: No such file or directory
76 | #include <alsa/asoundlib.h>
| ^~~~~~~~~~~~~~~~~~
compilation terminated.

浙公网安备 33010602011771号