向OpenEars添加新语言

时间:2023-02-01 11:27:09

I've recently started studying OpenEars speech recognition and it's great! But I also need to support speech recognition and dictation in other languages such as Russian, French and German.I've found that here are available various acoustic and language models.

我最近开始学习OpenEars语音识别,这很棒!但我还需要支持其他语言的语音识别和听写,如俄语,法语和德语。我发现这里有各种声学和语言模型。

But I cannot really understand - is that enough what I need to integrate extra language support in application?

但我真的不明白 - 在应用程序中集成额外语言支持需要的是什么?

Question is - what steps should I take in order to successfully integrate, for example russian, in Open Ears?

问题是 - 为了在Open Ears中成功整合,例如俄语,我应该采取什么步骤?

As far as I understood - all acoustic and language models for english language in Open Ears demo is located in folder hub4wsj_sc_8k . Same files can be found in voxforge language archives. So I just replaced them in demo. One thing is different - in demo English language, there also was a sendump 2MB large file, which is not located in voxforge language archives.There are two other files used in Open Ears demo:

据我所知 - Open Ears演示中所有英语语言和语言模型都位于文件夹hub4wsj_sc_8k中。在voxforge语言档案中可以找到相同的文件。所以我只是在演示中替换它们。有一点是不同的 - 在演示英语中,还有一个sendump 2MB大文件,它不在voxforge语言档案中。在Open Ears演示中还有两个其他文件:

  • OpenEars1.languagemodel
  • OpenEars1.languagemodel
  • OpenEars1.dic
  • OpenEars1.dic

These I replaced with:

这些我替换为:

  • msu_ru_nsh.lm.dmp
  • msu_ru_nsh.lm.dmp
  • msu_ru_nsh.dic
  • msu_ru_nsh.dic

as .dmp is similar to .languagemodel. But application is crashing without any error.

因为.dmp类似于.languagemodel。但应用程序崩溃没有任何错误。

What am I doing wrong? Thank You.

我究竟做错了什么?谢谢。

1 个解决方案

#1


10  

From my comments, reposted as an answer:

从我的评论中,转贴为答案:

[....] Step 1 for issues like this is to turn on OpenEarsLogging and verbosePocketsphinx, which will give you very fine-grained info on what is going wrong (search your console output for the words error and warning to save time). Instructions on doing this can be found in the docs. Feel free to bring questions to the OpenEars forums [....]: http://politepix.com/forums/openears You might also want to check out this thread: http://politepix.com/forums/topic/other-languages

[....]这样的问题的第1步是打开OpenEarsLogging和verbosePocketsphinx,这将为您提供关于出错的非常细粒度的信息(在控制台输出中搜索单词错误和警告以节省时间)。有关这样做的说明可以在文档中找到。随意向OpenEars论坛提问[....]:http://politepix.com/forums/openears您可能还想查看此主题:http://politepix.com/forums/topic/other -languages

The solution:

解决方案:

To follow up for later readers, after turning on logging we got this working by using the mixture_weights file as a substitute for sendump and by making sure that the phonetic dictionary used the phonemes that were present in the acoustic model rather than the English-language phonemes.

为了跟进后来的读者,在打开日志记录后,我们通过使用mixture_weights文件替代sendump并确保语音字典使用声学模型中存在的音素而不是英语语音音素来实现此工作。 。

The full discussion in which we accomplished this troubleshooting can be read here: http://www.politepix.com/forums/topic/using-russian-acoustic-model/

我们完成此故障排除的完整讨论可在此处阅读:http://www.politepix.com/forums/topic/using-russian-acoustic-model/


UPDATE: Since OpenEars 1.5 was released this week, it is possible to pass the path to any acoustic model as an argument to the main listening method, and there is a much more standardized method for packaging and referencing any acoustic model so you can have many acoustic models in the same app. The info in this forum post supersedes the info in the discussion I linked to in this answer: http://www.politepix.com/forums/topic/creating-an-acoustic-model-bundle-for-openears-1-5-and-up/ I left the rest of the answer for historical reasons and because there may be details in that discussion that are still useful, but it can be skipped in favor of the new link.

更新:由于本周发布了OpenEars 1.5,因此可以将路径传递给任何声学模型作为主要聆听方法的参数,并且有一种更标准化的方法可用于打包和参考任何声学模型,因此您可以拥有许多声学模型声学模型在同一个应用程序中。这个论坛帖子中的信息取代了我在这个答案中链接的讨论中的信息:http://www.politepix.com/forums/topic/creating-an-acoustic-model-bundle-for-openears-1-5 -and-up /我出于历史原因离开了答案的其余部分,因为在讨论中可能有详细信息仍然有用,但可以跳过它以支持新链接。

#1


10  

From my comments, reposted as an answer:

从我的评论中,转贴为答案:

[....] Step 1 for issues like this is to turn on OpenEarsLogging and verbosePocketsphinx, which will give you very fine-grained info on what is going wrong (search your console output for the words error and warning to save time). Instructions on doing this can be found in the docs. Feel free to bring questions to the OpenEars forums [....]: http://politepix.com/forums/openears You might also want to check out this thread: http://politepix.com/forums/topic/other-languages

[....]这样的问题的第1步是打开OpenEarsLogging和verbosePocketsphinx,这将为您提供关于出错的非常细粒度的信息(在控制台输出中搜索单词错误和警告以节省时间)。有关这样做的说明可以在文档中找到。随意向OpenEars论坛提问[....]:http://politepix.com/forums/openears您可能还想查看此主题:http://politepix.com/forums/topic/other -languages

The solution:

解决方案:

To follow up for later readers, after turning on logging we got this working by using the mixture_weights file as a substitute for sendump and by making sure that the phonetic dictionary used the phonemes that were present in the acoustic model rather than the English-language phonemes.

为了跟进后来的读者,在打开日志记录后,我们通过使用mixture_weights文件替代sendump并确保语音字典使用声学模型中存在的音素而不是英语语音音素来实现此工作。 。

The full discussion in which we accomplished this troubleshooting can be read here: http://www.politepix.com/forums/topic/using-russian-acoustic-model/

我们完成此故障排除的完整讨论可在此处阅读:http://www.politepix.com/forums/topic/using-russian-acoustic-model/


UPDATE: Since OpenEars 1.5 was released this week, it is possible to pass the path to any acoustic model as an argument to the main listening method, and there is a much more standardized method for packaging and referencing any acoustic model so you can have many acoustic models in the same app. The info in this forum post supersedes the info in the discussion I linked to in this answer: http://www.politepix.com/forums/topic/creating-an-acoustic-model-bundle-for-openears-1-5-and-up/ I left the rest of the answer for historical reasons and because there may be details in that discussion that are still useful, but it can be skipped in favor of the new link.

更新:由于本周发布了OpenEars 1.5,因此可以将路径传递给任何声学模型作为主要聆听方法的参数,并且有一种更标准化的方法可用于打包和参考任何声学模型,因此您可以拥有许多声学模型声学模型在同一个应用程序中。这个论坛帖子中的信息取代了我在这个答案中链接的讨论中的信息:http://www.politepix.com/forums/topic/creating-an-acoustic-model-bundle-for-openears-1-5 -and-up /我出于历史原因离开了答案的其余部分,因为在讨论中可能有详细信息仍然有用,但可以跳过它以支持新链接。