Menu

PocketSphinx for Android .raw file question

Help
2014-08-04
2014-09-18
  • Konstantin Startchev

    Dear Friends,
    I am building Magic mirror application for Android. The mirror should response to the classical question, “who is the most beautiful girl on the world” as well to some commands like “zoom in” and “zoom out”. This work amazingly well with PocketSphinx, but I found that .raw files are accumulated in the sync folder. My questions are:

    What is the use of these files?
    Could they use too much disk space?
    Can I clean these files periodically or simply stop saving them?

    Thank’s
    Konstantin

     
  • Nickolay V. Shmyrev

    I am building Magic mirror application for Android. The mirror should response to the classical question, “who is the most beautiful girl on the world” as well to some commands like “zoom in” and “zoom out”. This work amazingly well with PocketSphinx, but I found that .raw files are accumulated in the sync folder.

    Great, let us know the link once you release it

    What is the use of these files?

    They are useful for debuggin

    Could they use too much disk space?

    You need to disable them.

    Can I clean these files periodically or simply stop saving them?

    When you setup the recognizer with RecognizerSetup remove the call to setRawLogDir, if that will be unset, raw files will not be stored.

     
  • Konstantin Startchev

    Hi Nickolay,

    Thank you for the rapid and reliable help. It is ok now – no more .raw! I will be ready with the magic mirror soon and will be a pleasure to share here the link to the app.

    I changed a bit the tutorial demo for android in order to fit better to the mirror task. I have only one kw search (miro) and one grammar search and simply swap between them. All string comparisons are done in the onResult() function so the role of onPartialResult() and onEndOfSpeech() is just to stop the recogniser. The main difference is in the timer, which I implemented in onPartialResult() in order to stop the recogniser if activity longer then 5 sec is detected. This avoids problems with the background noise. Indeed the app works well in presence of CNN running on TV, which should be considered as very good resistance to noise.

    Please find below the testing code. I am new in ASR and CMU Sphinx and will appreciate any comments on the code.

    Cheers,
    Konstantin

     
  • Konstantin Startchev

    Ops, I think the code is not attached here it is again

     
    • Nickolay V. Shmyrev

      Hi

      Looks great, let me know if you meet any issues.

      I actually wanted to introduce recognizeWithTimeout method in our API, I think it definitely makes sense for many usecases. Then you will have more straightforward implementation.

       
      • Nickolay V. Shmyrev

        startRecognition("search", timeout) has been recently added.

         

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.