{"action":"closed","issue":{"url":"https://api.github.com/repos/cmusphinx/pocketsphinx-python/issues/47","repository_url":"https://api.github.com/repos/cmusphinx/pocketsphinx-python","labels_url":"https://api.github.com/repos/cmusphinx/pocketsphinx-python/issues/47/labels{/name}","comments_url":"https://api.github.com/repos/cmusphinx/pocketsphinx-python/issues/47/comments","events_url":"https://api.github.com/repos/cmusphinx/pocketsphinx-python/issues/47/events","html_url":"https://github.com/cmusphinx/pocketsphinx-python/issues/47","id":362823378,"node_id":"MDU6SXNzdWUzNjI4MjMzNzg=","number":47,"title":"didn't integrete for custom en-in AM and custom LM, ERROR: \"dict.c\", Phone 'AE' is mising in the acoustic model; word 'absolutely' ignored ","user":{"login":"MuruganR96","id":35978784,"node_id":"MDQ6VXNlcjM1OTc4Nzg0","avatar_url":"https://avatars3.githubusercontent.com/u/35978784?v=4","gravatar_id":"","url":"https://api.github.com/users/MuruganR96","html_url":"https://github.com/MuruganR96","followers_url":"https://api.github.com/users/MuruganR96/followers","following_url":"https://api.github.com/users/MuruganR96/following{/other_user}","gists_url":"https://api.github.com/users/MuruganR96/gists{/gist_id}","starred_url":"https://api.github.com/users/MuruganR96/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MuruganR96/subscriptions","organizations_url":"https://api.github.com/users/MuruganR96/orgs","repos_url":"https://api.github.com/users/MuruganR96/repos","events_url":"https://api.github.com/users/MuruganR96/events{/privacy}","received_events_url":"https://api.github.com/users/MuruganR96/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-09-22T03:47:41Z","updated_at":"2018-09-22T06:41:52Z","closed_at":"2018-09-22T06:41:52Z","author_association":"NONE","body":"### Problem\r\n-Sir I didn't integrete for custom en-in Acoustic Model(Adapting the default acoustic model-Indian English) and custom Language Model.\r\ni was download a acoustic model from this link: [](https://sourceforge.net/projects/cmusphinx/files/)\r\ni follow  the instruction this link: https://cmusphinx.github.io/wiki/tutorialam/\r\n\r\nsphinx_fe -argfile en_in/feat.params -samprate 16000 -c audio.fileids -di . -do . -ei wav -eo mfc -mswav yes\r\n\r\npocketsphinx_mdef_convert -text en_in/mdef en_in/mdef.txt\r\n\r\ncp -a /usr/local/libexec/sphinxtrain/bw .\r\ncp -a /usr/local/libexec/sphinxtrain/mk_s2sendump .\r\ncp -a /usr/local/libexec/sphinxtrain/map_adapt .\r\ncp -a /usr/local/libexec/sphinxtrain/mllr_solve .\r\n\r\n./bw \\\r\n -hmmdir en_in \\\r\n -moddeffn en_in/mdef.txt \\\r\n -ts2cbfn .cont. \\\r\n -feat 1s_c_d_dd \\\r\n -cmn current \\\r\n -agc none \\\r\n -dictfn en_in.dic \\\r\n -ctlfn audio.fileids \\\r\n -lsnfn audio.transcription \\\r\n -accumdir .\r\n\r\n\r\n./mllr_solve \\\r\n    -meanfn en_in/means \\\r\n    -varfn en_in/variances \\\r\n    -outmllrfn mllr_matrix -accumdir .\r\n\r\ncp -a en_in en_in_own\r\n\r\n./map_adapt \\\r\n    -moddeffn en_in/mdef.txt \\\r\n    -ts2cbfn .cont. \\\r\n    -meanfn en_in/means \\\r\n    -varfn en_in/variances \\\r\n    -mixwfn en_in/mixture_weights \\\r\n    -tmatfn en_in/transition_matrices \\\r\n    -accumdir . \\\r\n    -mapmeanfn en_in_own/means \\\r\n    -mapvarfn en_in_own/variances \\\r\n    -mapmixwfn en_in_own/mixture_weights \\\r\n    -maptmatfn en_in_own/transition_matrices\r\n\r\n./mk_s2sendump \\\r\n    -pocketsphinx yes \\\r\n    -moddeffn en_in_own/mdef.txt \\\r\n    -mixwfn en_in_own/mixture_weights \\\r\n    -sendumpfn en_in_own/sendump\r\n\r\npocketsphinx_continuous -hmm en_in_own -lm en-us.lm.bin -dict en_in.dic -infile 38.wav > 4.txt\r\n\r\nit is working but not predicting a particular words. words is relevant to banking sectors.so i build again own language model using language model build tool (Building a simple language model using a web service)\r\n\r\nown language model: lm.dict & lm.bin:\r\ntranscript file: own_vocab.txt\r\n[](http://www.speech.cs.cmu.edu/tools/product/1537337608_14460/)\r\n\r\nsphinx_lm_convert -i own.lm -o own.lm.bin\r\nsphinx_lm_convert -i own.lm.bin -ifmt bin -o own.lm -ofmt arpa\r\n\r\npocketsphinx_continuous -inmic yes -lm own.lm.bin -dict own.dic\r\n\r\nsir, it is working fine. detecting that particular words. but one confusion,\r\n\r\n> which default acoustic model it takes to run on that command \" pocketsphinx_continuous -inmic yes -lm own.lm.bin -dict own.dic\" ?\r\n\r\nbut i integrete these two AM and LM,  and run on,\r\n\r\npocketsphinx_continuous -hmm en_in_own -lm own.lm.bin -dict own.dic -infile 1.wav > result_own.txt\r\n\r\nit was not return any words. and it shows error. phone words dict in the LM not present in the AM.\r\n\r\nINFO: dict.c(333): Reading main dictionary: lm_model_resources/other/own.dic\r\nERROR: \"dict.c\", line 195: Line 5: Phone 'EH' is mising in the acoustic model; word 's' ignored\r\nERROR: \"dict.c\", line 195: Line 6: Phone 'EH' is mising in the acoustic model; word 's' ignored\r\nERROR: \"dict.c\", line 195: Line 7: Phone 'EY' is mising in the acoustic model; word 'a' ignored\r\nERROR: \"dict.c\", line 195: Line 8: Phone 'EY' is mising in the acoustic model; word 'able' ignored\r\nERROR: \"dict.c\", line 195: Line 9: Phone 'AH' is mising in the acoustic model; word 'about' ignored\r\nERROR: \"dict.c\", line 195: Line 10: Phone 'AE' is mising in the acoustic model; word 'absolutely' ignored\r\n\r\nbut some how i identify the issue. what it is,  phone words(own.dict) EH, EY, AH, AE always presents in the en_in acoustic model(INDIAN ENGLISH mdef phones) also but it is in SMALL CASE.(en_in/ mdef file). \r\nBUT OTHER ENGLISH mdef phones like wsj_all_cd30.mllt_cd_cont_4000, hub4_cd_continuous_8gau_1s_c_d_dd,  \r\nColumns definitions\r\n#base lft  rt p attrib tmat      ... state id's ...\r\n  SIL   -   - - filler    0      0      1      2 N\r\n  UNK   -   - -    n/a    1      3      4      5 N\r\n   aa   -   - -    n/a    2      6      7      8 N\r\n   ae   -   - -    n/a    3      9     10     11 N\r\n   ah   -   - -    n/a    4     12     13     14 N\r\n\r\ni tried something own.dic phones into small case but it was not reflect both AM & LM.\r\n\r\nBasically that LM tool gives these kind of structure words and phones. it is affecting acoustic model model. these two not sync.\r\n\r\ni tried another way something to create a own.lm.bin & own.dic also\r\n\r\n**Build an other way LM:**\r\ntext2wfreq < own_vocab.txt | wfreq2vocab > own_vocab.tmp.vocab\r\n\r\ntext2idngram -vocab own_vocab.tmp.vocab -idngram own_vocab.idngram < own_vocab.txt\r\n \r\nidngram2lm -vocab_type 0 -idngram own_vocab.idngram -vocab own_vocab.tmp.vocab -arpa own.lm\r\n\r\nsphinx_lm_convert -i own.lm -o own.lm.bin\r\n\r\n**Build a own.dic an other way:**\r\ni was followed these link:[](https://cmusphinx.github.io/wiki/tutorialdict/) &  [](https://github.com/cmusphinx/g2p-seq2seq)\r\n\r\ng2p-seq2seq --decode own_vocab.tmp.vocab --model_dir g2p-seq2seq/g2p-seq2seq-model-6.2-cmudict-nostress --output own.dic\r\npocketsphinx_continuous -lm own.lm.bin -dict own.dic -infile 10.wav > 10.txt\r\n\r\nit is working fine to predicting a particular words but  that confusion is,\r\n\r\n> which acoustic model is combined to run on that command \"pocketsphinx_continuous -lm own.lm.bin -dict own.dic -infile 10.wav > 10.txt\"\r\n\r\nbut i integrete these two AM and LM,  and run on,\r\npocketsphinx_continuous -lm own.lm.bin -dict own.dic -infile 10.wav > 10.txt -hmm en_in_own\r\n\r\nAgain it was return the same error. it was not display any text. the error log is,\r\n\r\nINFO: dict.c(333): Reading main dictionary: lm_model_resources/other/own.dic\r\nERROR: \"dict.c\", line 195: Line 5: Phone 'EH' is mising in the acoustic model; word 's' ignored\r\nERROR: \"dict.c\", line 195: Line 6: Phone 'EH' is mising in the acoustic model; word 's' ignored\r\nERROR: \"dict.c\", line 195: Line 7: Phone 'EY' is mising in the acoustic model; word 'a' ignored\r\nERROR: \"dict.c\", line 195: Line 8: Phone 'EY' is mising in the acoustic model; word 'able' ignored\r\nERROR: \"dict.c\", line 195: Line 9: Phone 'AH' is mising in the acoustic model; word 'about' ignored\r\nERROR: \"dict.c\", line 195: Line 10: Phone 'AE' is mising in the acoustic model; word 'absolutely' ignored\r\n\r\nLM tool produced dict(word-phone) format:\r\nA\tAH\r\nA(2)\tEY\r\nABLE\tEY B AH L\r\nABOUT\tAH B AW T\r\nABSOLUTELY\tAE B S AH L UW T L IY\r\n\r\nLM g2p-seq2seq produced dict(word-phone) format:\r\ns EH S\r\ns EH S\r\na EY\r\nable EY B AH L\r\nabout AH B AW T\r\nabsolutely AE B S AH L UW T L IY\r\n\r\nen_in_own mdef phones structure:\r\nia   f  aa s    n/a   20   2023   2038   2063 N\r\n   ia   f  ae e    n/a   20   2023   2038   2063 N\r\n   ia   f  ae s    n/a   20   2023   2038   2063 N\r\n   ia   f  ah e    n/a   20   2023   2038   2063 N\r\n   ia   f  ah s    n/a   20   2023   2038   2063 N\r\n   ia   f  ao e    n/a   20   2023   2038   2063 N\r\n   ia   f  ao s    n/a   20   2023   2038   2063 N\r\n   ia   f  aw e    n/a   20   2023   2038   2063 N\r\n\r\nreally is those small case was an issue or not? i was not able to predict this issue.\r\n\r\nSir How can i fix this issue? \r\ni didn't integrete for custom en-in AM and custom LM,  ERROR: \"dict.c\", Phone 'AE' is mising in the acoustic model; word 'absolutely' ignored\r\n\r\n- OS: Linux with version 16.04\r\n- Python3:\r\n- Sphinx version:\r\nPocketSphinx 5prealpha\r\n"}}
{"actor":{"display_login":"nshmyrev"}}