Pablo Duboue (KeaText) created OPENNLP-764:
----------------------------------------------

             Summary: UIMA NameFinder Annotator should call clearAdaptiveData
                 Key: OPENNLP-764
                 URL: https://issues.apache.org/jira/browse/OPENNLP-764
             Project: OpenNLP
          Issue Type: Bug
          Components: UIMA Integration
            Reporter: Pablo Duboue (KeaText)


Following the documentation 
(http://opennlp.apache.org/documentation/1.5.3/manual/opennlp.html#tools.namefind.recognition.api)
 and the discussion in OPENNLP-627, the adaptive data has to be called after 
each document has been processed.

This is missing in the UIMA integration, causing severe degradation when 
processing more than a few thousand documents.

The following patch fixes it:

Index: opennlp-uima/src/main/java/opennlp/uima/namefind/NameFinder.java
===================================================================
--- opennlp-uima/src/main/java/opennlp/uima/namefind/NameFinder.java    
(revision 1670422)
+++ opennlp-uima/src/main/java/opennlp/uima/namefind/NameFinder.java    
(working copy)
@@ -169,6 +169,8 @@
       documentConfidence.add(prob);
     }
 
+    mNameFinder.clearAdaptiveData();
+
     return names;
   }
 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to