<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt">Thanks Qiru..<br><br>But it does not work for me. I compiled the srilm using cygwin.<br>I reinstalled the srilm again in cygwin...still it does not work.<br><br><div><span><br></span></div><div><br></div> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <hr size="1"> <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> Qiru Zhou <qzhou@ispeech.org><br> <b><span style="font-weight: bold;">To:</span></b> Md. Akmal Haidar <akmalcuet00@yahoo.com>; srilm-user@speech.sri.com <br> <b><span style="font-weight: bold;">Sent:</span></b> Thursday, June 13, 2013 2:13:21 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [SRILM User List] SRILM command
in Matlab<br> </font> </div> <div class="y_msg_container"><br><div id="yiv2693762169">
<div>
Works for me using a MSVC 2010 compiled ngram:<br>
<br>
[status,result] =
system('D:\SLTools\SRI\srilm1.7\bin\x64\Release\ngram.exe -lm
D:\...\eg.mad.arpa -ppl D:\...\en-us.trans.txt -debug 2'<br>
<br>
>> result<br>
reading 100001 1-grams reading 864169 2-grams reading 1739458
3-grams<br>
...<br>
p( am | <unk> ...) = [1gram] 0.0033243 [ -2.4783 ]<br>
p( interested | am ...) = [2gram] 0.000292752 [ -3.5335 ]<br>
p( in | interested ...) = [3gram] 0.454779 [ -0.3422 ]<br>
p( learning | in ...) = [3gram] 0.00223203 [ -2.6513 ]<br>
p( more | learning ...) = [2gram] 0.00943844 [ -2.0251 ]<br>
p( <unk> | more ...) = [OOV] 0 [ -1.#INF ]<br>
p( restaurant | <unk> ...) = [1gram] 0.000581166 [
-3.2357 ]<br>
p( is | restaurant ...) = [2gram] 0.00385035 [ -2.4145 ]<br>
p( on | is ...) = [3gram] 0.0063841 [ -2.1949 ]<br>
p( the | on ...) = [3gram] 0.192486 [ -0.7156 ]<br>
p( fifth | the ...) = [3gram] 0.000952138 [ -3.0213 ]<br>
p( floor | fifth ...) = [2gram] 0.000440758 [ -3.3558 ]<br>
p( </s> | floor ...) = [3gram] 0.304299 [ -0.5167 ]<br>
...<br>
<br>
<div class="yiv2693762169moz-cite-prefix">On 6/13/2013 12:21 PM, Md. Akmal Haidar
wrote:<br>
</div>
<blockquote type="cite">
<div style="color:#000;background-color:#fff;font-family:times new roman, new york, times, serif;font-size:12pt;">Hi Qiru,<br>
<br>
I tried it. It didn't work. The result shows ' '.<br>
<br>
<div><span>Akmal<br>
</span></div>
<div><br>
</div>
<div style="font-family:times new roman, new york, times, serif;font-size:12pt;">
<div style="font-family:times new roman, new york, times, serif;font-size:12pt;">
<div dir="ltr">
<hr size="1"> <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> Qiru Zhou
<a rel="nofollow" class="yiv2693762169moz-txt-link-rfc2396E" ymailto="mailto:qzhou@ispeech.org" target="_blank" href="mailto:qzhou@ispeech.org"><qzhou@ispeech.org></a><br>
<b><span style="font-weight:bold;">To:</span></b> Md.
Akmal Haidar <a rel="nofollow" class="yiv2693762169moz-txt-link-rfc2396E" ymailto="mailto:akmalcuet00@yahoo.com" target="_blank" href="mailto:akmalcuet00@yahoo.com"><akmalcuet00@yahoo.com></a> <br>
<b><span style="font-weight:bold;">Sent:</span></b>
Thursday, June 13, 2013 10:42:26 AM<br>
<b><span style="font-weight:bold;">Subject:</span></b>
Re: [SRILM User List] SRILM command in Matlab<br>
</font> </div>
<div class="yiv2693762169y_msg_container"><br>
<div id="yiv2693762169">
<div> Try:<br>
[status,result] = system('<span>c:\cygwin\srilm\bin\cygwin\ngram
-lm LM -ppl test.txt -debug 2</span>')<br>
<br>
-- Qiru<br>
<br>
<div class="yiv2693762169moz-cite-prefix">On 6/12/2013
7:02 PM, Md. Akmal Haidar wrote:<br>
</div>
<blockquote type="cite">
<div style="color:#000;background-color:#fff;font-family:times new roman, new york, times, serif;font-size:12pt;">
<div>Hi,</div>
<div><br>
<span></span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>Does
anyone know how to execute srilm command in
Matlab?</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br>
<span></span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>For
example, I need to compute the perplexity of
an LM. I have to run the following command in
Matlab<br>
</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>c:\cygwin\srilm\bin\cygwin\ngram
-lm LM -ppl test.txt -debug 2</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br>
<span></span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>is
there any way to run this in Matlab?</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br>
<span></span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>Thanks</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>Best
Regards</span></div>
<div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>Akmal</span></div>
</div>
<br>
<fieldset class="yiv2693762169mimeAttachmentHeader"></fieldset>
<br>
<pre>_______________________________________________
SRILM-User site list
<a rel="nofollow" class="yiv2693762169moz-txt-link-abbreviated" ymailto="mailto:SRILM-User@speech.sri.com" target="_blank" href="mailto:SRILM-User@speech.sri.com">SRILM-User@speech.sri.com</a>
<a rel="nofollow" class="yiv2693762169moz-txt-link-freetext" target="_blank" href="http://www.speech.sri.com/mailman/listinfo/srilm-user">http://www.speech.sri.com/mailman/listinfo/srilm-user</a></pre>
</blockquote>
<br>
<pre class="yiv2693762169moz-signature">--
QIRU ZHOU | CHIEF SCIENTIST | iSPEECH, INC. | T 917.338.7723 | <a rel="nofollow" class="yiv2693762169moz-txt-link-abbreviated" ymailto="mailto:qzhou@iSpeech.org" target="_blank" href="mailto:qzhou@iSpeech.org">qzhou@iSpeech.org</a> | <a rel="nofollow" class="yiv2693762169moz-txt-link-abbreviated" target="_blank" href="http://www.ispeech.org/">www.iSpeech.org</a></pre>
</div>
</div>
<br>
<br>
</div>
</div>
</div>
</div>
</blockquote>
<br>
<pre class="yiv2693762169moz-signature">--
QIRU ZHOU | CHIEF SCIENTIST | iSPEECH, INC. | T 917.338.7723 | <a rel="nofollow" class="yiv2693762169moz-txt-link-abbreviated" ymailto="mailto:qzhou@iSpeech.org" target="_blank" href="mailto:qzhou@iSpeech.org">qzhou@iSpeech.org</a> | <a rel="nofollow" class="yiv2693762169moz-txt-link-abbreviated" target="_blank" href="http://www.ispeech.org/">www.iSpeech.org</a></pre>
</div>
</div><br><br></div> </div> </div> </div></body></html>