aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/makedict (follow)
Commit message (Expand)AuthorAgeFilesLines
* Small performance tweak•••Change-Id: Icd540742073d49d12e70b2d8bd99aaf7ccb5802d Jean Chalard2012-06-081-3/+3
* Remove a slew of Eclipse warnings.•••Change-Id: I03236386aea13fbd4fb8eaeee18e0008aa136502 Jean Chalard2012-06-081-1/+1
* Clean up some compiler warnings•••Change-Id: I604da15e65fc3cf807ec4033df4e4cd5ef0196fc Tadashi G. Takaoka2012-05-252-7/+9
* Use a formula packing more information into 4 bits field•••Bug: 6313806 Change-Id: Id0779bd69afae0bb4a4a285340c1eb306544663a Jean Chalard2012-05-151-8/+33
* Small optimization•••Performance gain is < 2% Bug: 6394357 Change-Id: I2b7da946788cf11d1a491efd20fb2bd2333c23d1 Jean Chalard2012-05-141-1/+1
* Small optimizations•••Bug: 6394357 Change-Id: I00ba1b5ab3d527b3768e28090c758ddd1629f281 Jean Chalard2012-05-141-4/+6
* More optimizations•••We don't merge tails anyway, and we can't do it any more because that would break the bigram lookup algorithm. The speedup is about 20%, and possibly double this if there are no bigrams. Bug: 6394357 Change-Id: I9eec11dda9000451706d280f120404a2acbea304 Jean Chalard2012-05-141-4/+11
* Some more obvious optimizations•••The speedup is about 15% Bug: 6394357 Change-Id: Ibd57363d9d793206dd916d8927366db4192083b6 Jean Chalard2012-05-141-3/+3
* Some obvious optimizations to makedict•••Bug: 6394357 Change-Id: Ibfd98aac2304ef50cf90b1de984736ddcfe7a4bc Jean Chalard2012-05-142-29/+22
* Write the bigram frequency following the new formula•••This also tests for bigram frequency against unigram frequency Bug: 6313806 Bug: 6028348 Change-Id: If7faa3559fee9f2496890f0bc0e081279e100854 Jean Chalard2012-05-111-5/+21
* Refactor a method•••Rename it, rename parameters, and add a parameter that will be necessary soon. Also, rescale the bigram frequency as necessary. Bug: 6313806 Change-Id: I192543cfb6ab6bccda4a1a53c8e67fbf50a257b0 Jean Chalard2012-05-111-10/+14
* Tidy up the MakedictLog class.•••Follow up to I436b2b7b Change-Id: Id17b134dab2f876b874a505e92a379c8b5567fa4 Ken Wakasa2012-05-051-12/+16
* Suppress debug log from makedict in LatinIME•••bug: 6447900 Change-Id: I436b2b7b261b422a7edca9cb99a4689b63877fe0 Ken Wakasa2012-05-051-1/+4
* Add a flag for bigram presence in the header•••This is a cherry-pick of Icb602762 onto jb-dev. Bug: 6355745 Change-Id: Icb602762bb0d81472f024fa491571062ec1fc4e9 Jean Chalard2012-04-262-4/+34
* Ignore bigrams that are not also listed as unigrams•••This is a cherry pick of I14b67e51 on jb-dev Bug: 6340915 Change-Id: Iaa512abe1b19ca640ea201f9761fd7f1416270ed Jean Chalard2012-04-262-25/+28
* Merge "Fix binary reading code performance."Jean Chalard2012-04-231-1/+10
|\
| * Fix binary reading code performance.•••This is not the Right fix ; the Right fix would be to read the file in a buffered way. However this delivers tolerable performance for a minimal amount of code changes. We may want to skip submitting this patch, but keep it around in case we need to use the functionality until we have a good patch. Change-Id: I1ba938f82acfd9436c3701d1078ff981afdbea60 Jean Chalard2012-04-241-1/+10
* | Fix a bug where a node size would be seen as increasing.•••The core reason for this is quite shrewd. When a word is a bigram of itself, the corresponding chargroup will have a bigram referring to itself. When computing bigram offsets, we use cached addresses of chargroups, but we compute the size of the node as we go. Hence, a discrepancy may happen between the base offset as seen by the bigram (which uses the recomputed value) and the target offset (which uses the cached value). When this happens, the cached node address is too large. The relative offset is negative, which is expected, since it points to this very charnode whose start is a few bytes earlier. But since the cached address is too large, the offset is computed as smaller than it should be. On the next pass, the cache has been refreshed with the newly computed size and the seen offset is now correct (or at least, much closer to correct). The correct value is larger than the previously computed offset, which was too small. If it happens that it crosses the -255 or -65335 boundary, the address will be seen as needing 1 more byte than previously computed. If this is the only change in size of this node, the node will be seen as having a larger size than previously, which is unexpected. Debug code was catching this and crashing the program. So this case is very rare, but in an even rarer occurence, it may happen that in the same node, another chargroup happens to decrease it size by the same amount. In this case, the node may be seen as having not been modified. This is probably extremely rare. If on top of this, it happens that no other node has been modified, then the file may be seen as complete, and the discrepancy left as is in the file, leading to a broken file. The probability that this happens is abyssally low, but the bug exists, and the current debug code would not have caught this. To further catch similar bugs, this change also modifies the test that decides if the node has changed. On grounds that all components of a node may only decrease in size with each successive pass, it's theoritically safe to assume that the same size means the node contents have not changed, but in case of a bug like the bug above where a component wrongly grows while another shrinks and both cancel each other out, the new code will catch this. Also, this change adds a check against the number of passses, to avoid infinite loops in case of a bug in the computation code. This change fixes this bug by updating the cached address of each chargroup as we go. This eliminates the discrepancy and fixes the bug. Bug: 6383103 Change-Id: Ia3f450e22c87c4c193cea8ddb157aebd5f224f01 Jean Chalard2012-04-241-5/+25
|/
* Change binary dictionary output buffer size to match dictionary size.•••Bug: 6355943 Change-Id: Iaab7bc16ba0dbc7bfde70b06e7bd355519838831 Tom Ouyang2012-04-191-32/+65
* Add support for German umlaut and French ligatures flags•••Bug: 6202812 Change-Id: Ib4a7f96f6ef86c840069b15d04393f84d428c176 Jean Chalard2012-04-062-9/+26
* Remove constructors•••And small cleanup. Change-Id: I1de903f42c1b8d57a488be2162e0b94055a6d1f2 Jean Chalard2012-04-061-10/+0
* Remove the shortcutOnly attribute which is now useless.•••Change-Id: Ifccdfdaf7c0066bb7728981503baceff0fedb71f Jean Chalard2012-04-063-61/+20
* Add a simple way to input dictionary header attributes•••Just add them as an attribute to the root of the XML node. Bug: 6202812 Change-Id: Idf040bfebf20a72f9e4370930a85d97df593f484 Jean Chalard2012-04-032-4/+31
* Remove useless adding of shortcut as unigrams.•••Change-Id: I1f50ebf00d6dd0dad4114fad86ace5b7b304613a Jean Chalard2012-03-281-4/+0
* Add read support for string shortcuts for makedict.•••Change-Id: I48ee4fc9ac703ad2a680b3cd848de91c415ea3c8 Jean Chalard2012-03-282-35/+26
* Change the format of the shortcuts in the binary dict.•••This only includes the write part of the change. The read part is coming in a different commit. Change-Id: Iabe7af6cd134462dc19245f5400719920ed31c8f Jean Chalard2012-03-281-44/+107
* Merge "Add support for updating and adding bigrams to existing nodes."Tom Ouyang2012-03-231-29/+128
|\
| * Add support for updating and adding bigrams to existing nodes.•••Bug: 6188977 Change-Id: I48aca8ba199247d73395ab13b9d1976f4e739208 Tom Ouyang2012-03-231-29/+128
* | Add a missing comparison in Word.equals()•••Follow up to I94e2e29c bug: 6209651 Change-Id: Iff2daca8c2678e2d1796f98d6db738f109e3d03f Ken Wakasa2012-03-231-0/+1
* | Add missing Word.hashCode()•••Some cleanups too. bug: 6209651 Change-Id: I94e2e29c92e90e554e4952d277d590e093766c4f Ken Wakasa2012-03-232-0/+35
|/
* Revive the Makefile for makedict•••Follow up to I4d2ef504. Address a compiler warning and a small optimization as well. bug: 6188977 bug: 6209651 Change-Id: Ibc9da51d48ebf0b8815ad0bb2f697242970ba8f7 Ken Wakasa2012-03-221-9/+3
* Move makedict to LatinIME android keyboard.•••Bug: 6188977 Change-Id: I4d2ef504bb983abbda3cb52ee450cb46f58d95cf Tom Ouyang2012-03-217-3/+2085
* Add a dummy file and package for make dict•••Change-Id: I195fd42f2a773bcc6fab0a61336a1c15d97902bb satok2012-03-191-0/+21