优化data_generator代码

This commit is contained in:
nl 2019-01-19 11:27:57 +08:00
parent cee06b5720
commit fd150c047e
2 changed files with 4 additions and 4 deletions

View File

@ -14,7 +14,7 @@ from LanguageModel import ModelLanguage
datapath = './' datapath = './'
modelpath = 'model_speech/' modelpath = 'model_speech/'
ms = ModelSpeech(datapath) ms = ModelSpeech(datapath)
ms.LoadModel(modelpath + 'm251/speech_model251_e_0_step_117000.model') ms.LoadModel(modelpath + 'm251/speech_model251_e_0_step_12000.model')
ml = ModelLanguage('model_language') ml = ModelLanguage('model_language')
ml.LoadModel() ml.LoadModel()

View File

@ -29,14 +29,14 @@ else:
ms = ModelSpeech(datapath) ms = ModelSpeech(datapath)
#ms.LoadModel(modelpath + 'm22_2\\0\\speech_model22_e_0_step_257000.model') #ms.LoadModel(modelpath + 'm22_2\\0\\speech_model22_e_0_step_257000.model')
ms.LoadModel(modelpath + 'm251\\speech_model251_e_0_step_411000.model') ms.LoadModel(modelpath + 'm251\\speech_model251_e_0_step_117000.model')
#ms.TestModel(datapath, str_dataset='test', data_count = 64, out_report = True) #ms.TestModel(datapath, str_dataset='test', data_count = 64, out_report = True)
#r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\ST-CMDS-20170001_1-OS\\20170001P00241I0052.wav') r = ms.RecognizeSpeech_FromFile('D:\\语音数据集\\ST-CMDS-20170001_1-OS\\20170001P00241I0052.wav')
#r = ms.RecognizeSpeech_FromFile('E:\语音数据集\ST-CMDS-20170001_1-OS\\20170001P00241I0053.wav') #r = ms.RecognizeSpeech_FromFile('E:\语音数据集\ST-CMDS-20170001_1-OS\\20170001P00241I0053.wav')
#r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\ST-CMDS-20170001_1-OS\\20170001P00020I0087.wav') #r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\ST-CMDS-20170001_1-OS\\20170001P00020I0087.wav')
#r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\wav\\train\\A11\\A11_167.WAV') #r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\wav\\train\\A11\\A11_167.WAV')
r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\wav\\test\\D4\\D4_750.wav') #r = ms.RecognizeSpeech_FromFile('E:\\语音数据集\\wav\\test\\D4\\D4_750.wav')
K.clear_session() K.clear_session()