diff options
author | 2014-02-05 21:44:55 +0900 | |
---|---|---|
committer | 2014-02-05 21:44:55 +0900 | |
commit | df1d3e733e2b000c776e74b54d3c62f0d433b013 (patch) | |
tree | 8461b6f1538fdf963049f5ef473534b427bcf887 /java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java | |
parent | 75a3df30f6282e4ff93a5c71c7d55fbbcf462d0a (diff) | |
download | latinime-df1d3e733e2b000c776e74b54d3c62f0d433b013.tar.gz latinime-df1d3e733e2b000c776e74b54d3c62f0d433b013.tar.xz latinime-df1d3e733e2b000c776e74b54d3c62f0d433b013.zip |
Make WeightedString have ProbabilityInfo.
Bug: 11281877
Bug: 12810574
Change-Id: I265e3d8654c75766cd0e0d09d67ef62b4566298a
Diffstat (limited to 'java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java b/java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java index 369184573..9f2345962 100644 --- a/java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java +++ b/java/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderUtils.java @@ -511,7 +511,7 @@ public final class BinaryDictDecoderUtils { final WeightedString word = getWordAtPosition(dictDecoder, headerSize, bigram.mAddress, options); final int reconstructedFrequency = - BinaryDictIOUtils.reconstructBigramFrequency(word.mFrequency, + BinaryDictIOUtils.reconstructBigramFrequency(word.getProbability(), bigram.mFrequency); bigrams.add(new WeightedString(word.mWord, reconstructedFrequency)); } @@ -618,7 +618,7 @@ public final class BinaryDictDecoderUtils { // words that are not also registered as unigrams so we don't have to avoid // them explicitly here. for (final WeightedString bigram : w.mBigrams) { - newDict.setBigram(w.mWord, bigram.mWord, bigram.mFrequency); + newDict.setBigram(w.mWord, bigram.mWord, bigram.getProbability()); } } } |