GitHub user tokee opened a pull request:
https://github.com/apache/tika/pull/29
2 times speed increase of language profile distance calculation
The distance calculation for language profiles creates a Set of Strings
with each call and performs hashtable lookups for all those Strings. This patch
creates and caches compact structures that are iterated sequentially. The
result is a factor 2 speed up (see the performance test in
LanguageIdentifierTest).
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/tokee/tika language-performance
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/tika/pull/29.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #29
commit 7794005daa68a3b663d2d4f9c3373ed718ae3ad7
Author: Toke Eskildsen
Date: 2015-02-14T00:01:46Z
2 times speed increase of language profile distance calculation
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---