I'm trying to get the sphinx2-demo to work on Redhat Linux Enterprise 4. The results are terrible, but having poked around the code a bit now, I'm surprised I'm getting any results at all!
BTW, what I see is very much like the previous poster described, only the first utteranc seems to be recognized.
I can recored and replay sound, also the Sphinx 4 demos work just fine for me, so I don't believe I have a problem with audio in itself. However the soundcard on my machind runs with an ALSA driver. In fact RHEL 4 release notes say that ALSA has replaced the OSS drivers for their "sound subsystem". In the usual ./configure step, ad_alsa.c is not even setup to be compiled, it is ad_oss.c which is compiled. The include file <sys/soundcard.h> is present on the system which seems to be good enough for compilation. But since the oss libraries themselves are not installed (at least not hooked up to my soundcard, which runs with an ALSA driver), I am surprised that the sphinx 2 demo detects any audio at all, and on occasion even prints out "go forward seven feet"! Anyway this a mystery for me.
But I thought I should be using ALSA anyway, so I ran configure again with --with-alsa option. The compilation fails. The interfaces in <sys/asoundlib.h> have changed, for example the line: "struct snd_pcm_channel_params params;" no longer makes sense. I'm guessing this struct was declared in an old version of asoundlib.h
Anyway, I'm basically after some suggestions. Have I identified the source of the problem, or am I off base? If the problem is with the driver, what do you suggest? Is it worthwhile to try get the ALSA option to work, or should I get a new soundcard or redeploy my existing soundcard with OSS?
Many thanks in advance for any help.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Thanks very much. I didn't know about alsa-oss emulation. This explains why I'm capturing something, and occasionally it is even correct. The problem is elsewhere as you say.
It seems that you contributed an ad_alsa.c in the tracker referenced. I will try it (for fun) anyway.
Ali
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
As described here (for sphin3): http://sourceforge.net/tracker/index.php?func=detail&aid=1281076&group_id=1904&atid=101904
the alsa implementation is a little outdated (and not usable) but it shouldnt be any problem to use it (sphinx and oss) with the alsa-oss emulation (I think it works that way in your case because you can capture something) so i think your problem should be somewhere else (if it exists at all).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm trying to get the sphinx2-demo to work on Redhat Linux Enterprise 4. The results are terrible, but having poked around the code a bit now, I'm surprised I'm getting any results at all!
BTW, what I see is very much like the previous poster described, only the first utteranc seems to be recognized.
I can recored and replay sound, also the Sphinx 4 demos work just fine for me, so I don't believe I have a problem with audio in itself. However the soundcard on my machind runs with an ALSA driver. In fact RHEL 4 release notes say that ALSA has replaced the OSS drivers for their "sound subsystem". In the usual ./configure step, ad_alsa.c is not even setup to be compiled, it is ad_oss.c which is compiled. The include file <sys/soundcard.h> is present on the system which seems to be good enough for compilation. But since the oss libraries themselves are not installed (at least not hooked up to my soundcard, which runs with an ALSA driver), I am surprised that the sphinx 2 demo detects any audio at all, and on occasion even prints out "go forward seven feet"! Anyway this a mystery for me.
But I thought I should be using ALSA anyway, so I ran configure again with --with-alsa option. The compilation fails. The interfaces in <sys/asoundlib.h> have changed, for example the line: "struct snd_pcm_channel_params params;" no longer makes sense. I'm guessing this struct was declared in an old version of asoundlib.h
Anyway, I'm basically after some suggestions. Have I identified the source of the problem, or am I off base? If the problem is with the driver, what do you suggest? Is it worthwhile to try get the ALSA option to work, or should I get a new soundcard or redeploy my existing soundcard with OSS?
Many thanks in advance for any help.
Thanks very much. I didn't know about alsa-oss emulation. This explains why I'm capturing something, and occasionally it is even correct. The problem is elsewhere as you say.
It seems that you contributed an ad_alsa.c in the tracker referenced. I will try it (for fun) anyway.
Ali
Hi,
As described here (for sphin3): http://sourceforge.net/tracker/index.php?func=detail&aid=1281076&group_id=1904&atid=101904
the alsa implementation is a little outdated (and not usable) but it shouldnt be any problem to use it (sphinx and oss) with the alsa-oss emulation (I think it works that way in your case because you can capture something) so i think your problem should be somewhere else (if it exists at all).