diff options
author | 2012-01-27 00:03:29 -0800 | |
---|---|---|
committer | 2012-01-27 00:03:29 -0800 | |
commit | 0920173bcb2c9c4e4dbe9f122862aae03b52724d (patch) | |
tree | cef7457b20c8c8725c1a84ab8741d065a54ff557 /native/src/correction.h | |
parent | fecba89713650871bf70cca08a77e6db360c0579 (diff) | |
parent | 23f486f770883ed690d897ac71de0184456bf24e (diff) | |
download | latinime-0920173bcb2c9c4e4dbe9f122862aae03b52724d.tar.gz latinime-0920173bcb2c9c4e4dbe9f122862aae03b52724d.tar.xz latinime-0920173bcb2c9c4e4dbe9f122862aae03b52724d.zip |
am 23f486f7: Merge "Merge missing space and mistyped space correction algorithm"
* commit '23f486f770883ed690d897ac71de0184456bf24e':
Merge missing space and mistyped space correction algorithm
Diffstat (limited to 'native/src/correction.h')
-rw-r--r-- | native/src/correction.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/native/src/correction.h b/native/src/correction.h index aec7bbd73..b246070fe 100644 --- a/native/src/correction.h +++ b/native/src/correction.h @@ -122,7 +122,8 @@ class Correction { bool needsToPrune() const; int getFreqForSplitTwoWords( - const int firstFreq, const int secondFreq, const unsigned short *word); + const int *freqArray, const int *wordLengthArray, const bool isSpaceProximity, + const unsigned short *word); int getFinalFreq(const int freq, unsigned short **word, int* wordLength); int getFinalFreqForSubQueue(const int freq, unsigned short **word, int* wordLength, const int inputLength); @@ -150,8 +151,9 @@ class Correction { static int calculateFinalFreq(const int inputIndex, const int depth, const int freq, int *editDistanceTable, const Correction* correction, const int inputLength); - static int calcFreqForSplitTwoWords(const int firstFreq, const int secondFreq, - const Correction* correction, const unsigned short *word); + static int calcFreqForSplitTwoWords(const int *freqArray, const int *wordLengthArray, + const Correction* correction, const bool isSpaceProximity, + const unsigned short *word); static double calcNormalizedScore(const unsigned short* before, const int beforeLength, const unsigned short* after, const int afterLength, const int score); static int editDistance(const unsigned short* before, |