我想将音频文件转换为文本。所以,我找到了链接 Can CMU Sphinx be set up to recognize ~200 words 使用CMUSphinx库来执行此操作。这样做我跟着
http://cmusphinx.sourceforge.net/2011/05/building-pocketsphinx-on-android/ 并尝试运行Android示例。但我在那里找不到示例项目。如果是,请使用一些用于编译此代码的代码,请告诉我如何在窗口特定的OS中运行。是否需要安装cygwig和swig来编译构建。
编辑: 我已经从http://code.google.com/p/itce-team8-2012/source/browse/trunk/PocketSphinxAndroidDemo下载了代码。现在当我编译并运行代码而不是应用程序崩溃时。 查找日志如下
04-15 17:58:12.584: D/dalvikvm(19618): Trying to load lib /data/data/edu.cmu.pocketsphinx.demo/lib/libpocketsphinx_jni.so 0x41b9e1c0
04-15 17:58:12.584: D/dalvikvm(19618): Added shared lib /data/data/edu.cmu.pocketsphinx.demo/lib/libpocketsphinx_jni.so 0x41b9e1c0
04-15 17:58:12.584: D/dalvikvm(19618): No JNI_OnLoad found in /data/data/edu.cmu.pocketsphinx.demo/lib/libpocketsphinx_jni.so 0x41b9e1c0, skipping init
04-15 17:58:12.649: D/edu.cmu.pocketsphinx.demo.RecognizerTask(19618): waiting
04-15 17:58:12.684: D/libEGL(19618): loaded /system/lib/egl/libEGL_mali.so
04-15 17:58:12.689: D/libEGL(19618): loaded /system/lib/egl/libGLESv1_CM_mali.so
04-15 17:58:12.689: D/libEGL(19618): loaded /system/lib/egl/libGLESv2_mali.so
04-15 17:58:12.694: D/(19618): Device driver API match
04-15 17:58:12.694: D/(19618): Device driver API version: 10
04-15 17:58:12.694: D/(19618): User space API version: 10
04-15 17:58:12.694: D/(19618): mali: REVISION=Linux-r2p4-02rel0 BUILD_DATE=Tue Oct 16 15:37:13 KST 2012
04-15 17:58:12.729: D/OpenGLRenderer(19618): Enabling debug mode 0
04-15 17:58:12.729: E/SensorManager(19618): thread start
04-15 17:58:12.729: D/SensorManager(19618): registerListener :: handle = 0 name= LSM330DLC 3-axis Accelerometer delay= 200000 Listener= android.view.OrientationEventListener$SensorEventListenerImpl@41bc3538
04-15 17:58:14.374: D/edu.cmu.pocketsphinx.demo.RecognizerTask(19618): signalling START
04-15 17:58:14.374: D/edu.cmu.pocketsphinx.demo.RecognizerTask(19618): signalled START
04-15 17:58:14.374: D/edu.cmu.pocketsphinx.demo.RecognizerTask(19618): gotSTART
04-15 17:58:14.374: D/edu.cmu.pocketsphinx.demo.RecognizerTask(19618): START
04-15 17:58:14.499: A/libc(19618): Fatal signal 11 (SIGSEGV) at 0x0000001c (code=1), thread 19639 (Thread-3329)
答案 0 :(得分:2)
我已成功运行演示。我的错误是我没有更改配置文件中的SD卡路径。