I've just fixed this; I changed the word kerrang to uppercase in my grammar
file and it is recognized by pocketsphinx now.
I'm not sure why, but normal words like "goodbye" only work if they are in
upper case in my grammar; the new word "kerrang" only works if it's upper
case.
This is now solved by adding any unknown words pronunciations to
/usr/share/pocketsphinx/model/lm/en_US/cmu07a.dic
with the word in lower case and pronunciation in caps.
What I don't understand is that even though I pass my own generated .dic file
to my program (modified pocketsphinx_continous); it ignores the dictionary and
uses the default /usr/share/pocketsphinx/model/lm/en_US/cmu07a.dic
Can someone explain this behaviour? I'm confused.
I would like my program to be able to dynamically add new words (radio
stations), then write a script to add these automatically. But at this stage
it'll be difficult as I would need to check if the words was previously
unknown, then add it to the global .dic - but this defeats the object of
specifying your own dictionary file....
Any advice would be greatly appreciated!
Thanks!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
What I don't understand is that even though I pass my own generated .dic
file to my program (modified pocketsphinx_continous); it ignores the
dictionary and uses the default
/usr/share/pocketsphinx/model/lm/en_US/cmu07a.dic Can someone explain this
behaviour?
It's easy to explain. Your modifications were not correct, you had to modify
some other place.
I'm confused. I would like my program to be able to dynamically add new
words (radio stations), then write a script to add these automatically. But at
this stage it'll be difficult as I would need to check if the words was
previously unknown, then add it to the global .dic - but this defeats the
object of specifying your own dictionary file....
You can use ps_add_word function to add the words to the dictionary. There is
no need to modify the global one.
In case you still decide to modify the global dictionary, you need to do it
properly
I'm creating a language model file with bin/x86-linux/pronounce from the
trunk of Logios. In the logs it says:
New g2p support has just been committed to Sphinxtrain trunk. You might want
to try to use it instead of pronounce.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I'm creating a language model file with bin/x86-linux/pronounce from the trunk
of Logios. In the logs it says:
All other words say 'Main '.
When running my program it complains that the word "kerrang" is not in the
dictionary, however the generated .dic file contains:
Am I doing something wrong?
can you provide language model and dictionary that you are trying to use in
your program?
I've just fixed this; I changed the word kerrang to uppercase in my grammar
file and it is recognized by pocketsphinx now.
I'm not sure why, but normal words like "goodbye" only work if they are in
upper case in my grammar; the new word "kerrang" only works if it's upper
case.
Here is my .dic:
LM: http://pastebin.com/NAg1rYPN
Grammar:
Sorry, I meant: normal words like "goodbye" only work if they are in lower
case in my grammar;
This is now solved by adding any unknown words pronunciations to
with the word in lower case and pronunciation in caps.
What I don't understand is that even though I pass my own generated .dic file
to my program (modified pocketsphinx_continous); it ignores the dictionary and
uses the default /usr/share/pocketsphinx/model/lm/en_US/cmu07a.dic
Can someone explain this behaviour? I'm confused.
I would like my program to be able to dynamically add new words (radio
stations), then write a script to add these automatically. But at this stage
it'll be difficult as I would need to check if the words was previously
unknown, then add it to the global .dic - but this defeats the object of
specifying your own dictionary file....
Any advice would be greatly appreciated!
Thanks!
It's easy to explain. Your modifications were not correct, you had to modify
some other place.
You can use ps_add_word function to add the words to the dictionary. There is
no need to modify the global one.
In case you still decide to modify the global dictionary, you need to do it
properly
New g2p support has just been committed to Sphinxtrain trunk. You might want
to try to use it instead of pronounce.
Thanks for your reply :)