I compiled with visual studio community.
The file that I originally wanted to test this on was over an hour long, so I tried it with a 3 second piece of audio, nevertheless, the same thing happened. Here are the command line arguments that I used:
C:\path\to\pocketsphinx_continuous -infile C:\path\to\file.wav -hmm C:\path\to\en-us -kws_threshold 1e-40 -keyphrase "what I need to detect" -time yes
I was told to convert the file like this:
ffmpeg -i file.mp3 -ar 16000 -ac 1 file.wav
so I did, but I also tried it without the conversion.
When I run this the program seems to run okay, but then it crashes here:
INFO: tmat.c(206): Reading HMM transition probability matrices: en-us/transition_matrices
When run with the debug version of sphinxbase.dll, an alert pops up containing this:
Debug Assertion Failed!
Program: pocketsphinx_continuous.exe
File: minkernel\crts\ucrt\src\appcrt\lowio\read.cpp
Line: 387
Expression: _osfile(fh) & FOPEN
just before the crash. I have tried everything I can think of, but nothing seems to work so any help would be greatly appreciated.
When you download the file, in bin/Release are the, already compiled, binaries. Use these instead of compiling it yourself.
Thanks to Nikolay Shmyrev