1
0
mirror of https://github.com/aidygus/LinVAM.git synced 2024-11-23 17:18:06 +11:00

Update another Decoder config, remove whitespaces

This commit is contained in:
smirgol 2023-06-29 09:28:40 +02:00
parent 32d30656c4
commit 407b3e3d04

View File

@ -224,14 +224,14 @@ def kws_analysis(dic, kwlist):
modeldir = "/usr/local/share/pocketsphinx/model/" modeldir = "/usr/local/share/pocketsphinx/model/"
# Create a decoder with certain model # Create a decoder with certain model
config = Decoder.default_config() config = Config(
config.set_string('-hmm', os.path.join(modeldir, 'en-us/en-us')) hmm=os.path.join(modeldir, 'en-us/en-us'),
config.set_string('-dict', dic) dict=dic,
config.set_string('-kws', kwlist) kws=kwlist,
config.set_string('-dither', "no") dither="no",
config.set_string('-logfn', '/dev/null') featparams=os.path.join(os.path.join(modeldir, 'en-us/en-us'), "feat.params"),
config.set_string('-featparams', os.path.join(os.path.join(modeldir, logfn='/dev/null'
'en-us/en-us'), "feat.params")) )
stream = open(OUTPUT_FILENAME, "rb") stream = open(OUTPUT_FILENAME, "rb")