[SRILM User List] a question about srilm

Andreas Stolcke stolcke at speech.sri.com
Thu Feb 4 09:15:52 PST 2010


On 2/3/2010 9:18 PM, Sun, Xie (MU-Student) wrote:
>  Dear Dr.Andreas Stolcke,
>
> I am PhD student from University of Missouri. My name is Xie Sun. 
> Right now I am using the SRILM toolkit to train a language model. I 
> want to use the model adaptation function. I am using the command as 
> below:
>
> ngram -lm main_model  -adapt-marginals model_adapted  -base-marginals 
> unigram_model -ppl test_file
>
> where the unigram_model is coming from the main_model and 
> model_adapted is the mode I want to adapt.
I'm assuming model_adapted refers to the marginals of the adaptation 
data.  Then this command is correct.
Note that -base-marginals needs to be specified only if the unadapted 
unigrams are different from the unigrams in main_model.
>
> I am not sure if what I did is correct. Besides, one more important 
> question is how I can output the adapted model. I used the option 
> -write-lm. But it does not work. Could you give me some hints? I will 
> really appreciate your help.
The AdaptMarginals does not support -write-lm at this point.  It should 
be very slow as you'd have to compute the normalization for every 
context appearing in the LM.
You can simulate the effect of -write-lm by employing the -rescore-ngram 
option:

ngram -lm -main_model -adapt-marginals ... -rescore-ngram main_model 
write-lm new_model

Again, this will take a very long time for regular-sized LMs.

Andreas

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.speech.sri.com/pipermail/srilm-user/attachments/20100204/bbcc3565/attachment.html>


More information about the SRILM-User mailing list