google ngram test: LogProbability is NaN

82 views
Skip to first unread message

李若冰

unread,
Apr 27, 2015, 3:07:05 AM4/27/15
to berkeleyl...@googlegroups.com

I've met a problem that, I want to compute the prob of a sentence based on google book ngram corpus, but I got always NaN. all the lm file is downloaded from the official page.

command: java -ea -mx16g -server -cp ./src edu.berkeley.nlp.lm.io.ComputeLogProbabilityOfTextStream -o output.txt -g vocab_cs.gz eng.blm test.txt

test.txt:

i want it that way.

any help?

李若冰

unread,
Apr 27, 2015, 5:42:06 AM4/27/15
to berkeleyl...@googlegroups.com
thanks all the same. problem solved.

在 2015年4月27日星期一 UTC+8下午3:07:05,李若冰写道:

miluette

unread,
Jan 18, 2016, 5:34:33 PM1/18/16
to berkeleylm-discuss
Hello:)
I am having the exact same problem right now. How did you solve it?

李若冰

unread,
Jan 18, 2016, 8:52:07 PM1/18/16
to berkeleyl...@googlegroups.com
things long time ago, you can give me your code and I will check it(model is the same, isn't it?).

--
You received this message because you are subscribed to a topic in the Google Groups "berkeleylm-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/berkeleylm-discuss/TCnSSdA242M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to berkeleylm-disc...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

miluette

unread,
Jan 19, 2016, 4:24:06 AM1/19/16
to berkeleylm-discuss
I ran this on terminal:

"Das ist ein Satz"| java -ea -mx1000m -server -cp ./src edu.berkeley.nlp.lm.io.ComputeLogProbabilityOfTextStream  -g vocab_cs.gz  ./src/ger.blm.gz 

output
Reading Google Binary ./src/ger.blm.gz with vocab vocab_cs.gz {
} [12s]
Scoring file -; current log probability is 0.0 {
} [0s]
Log probability of text is: NaN


the vocab_cs.gz and ger.blm.gz files are downloaded from http://tomato.banatao.berkeley.edu:8080/berkeleylm_binaries/
To unsubscribe from this group and all its topics, send an email to berkeleylm-discuss+unsub...@googlegroups.com.

李若冰

unread,
Jan 19, 2016, 5:27:27 AM1/19/16
to berkeleyl...@googlegroups.com
The way I run is a little different, however, I can get the right outcome.

To unsubscribe from this group and all its topics, send an email to berkeleylm-disc...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "berkeleylm-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/berkeleylm-discuss/TCnSSdA242M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to berkeleylm-disc...@googlegroups.com.

wei sun

unread,
Nov 19, 2016, 5:22:05 PM11/19/16
to berkeleylm-discuss
how to solve this problem??????

在 2016年1月19日星期二 UTC-5上午5:27:27,李若冰写道:
To unsubscribe from this group and all its topics, send an email to berkeleylm-discuss+unsub...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "berkeleylm-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/berkeleylm-discuss/TCnSSdA242M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to berkeleylm-discuss+unsub...@googlegroups.com.

jeremy

unread,
Nov 19, 2016, 5:55:47 PM11/19/16
to berkeleylm-discuss
how can you solve this problem??

在 2015年4月27日星期一 UTC-4上午3:07:05,李若冰写道:
Reply all
Reply to author
Forward
0 new messages