opennlp.model
Class OnePassDataIndexer

java.lang.Object
  extended by opennlp.model.AbstractDataIndexer
      extended by opennlp.model.OnePassDataIndexer
All Implemented Interfaces:
DataIndexer
Direct Known Subclasses:
OnePassRealValueDataIndexer

public class OnePassDataIndexer
extends AbstractDataIndexer

An indexer for maxent model data which handles cutoffs for uncommon contextual predicates and provides a unique integer index for each of the predicates.


Constructor Summary
OnePassDataIndexer(EventStream eventStream)
          One argument constructor for DataIndexer which calls the two argument constructor assuming no cutoff.
OnePassDataIndexer(EventStream eventStream, int cutoff)
           
OnePassDataIndexer(EventStream eventStream, int cutoff, boolean sort)
          Two argument constructor for DataIndexer.
 
Method Summary
 
Methods inherited from class opennlp.model.AbstractDataIndexer
getContexts, getNumEvents, getNumTimesEventsSeen, getOutcomeLabels, getOutcomeList, getPredCounts, getPredLabels, getValues
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OnePassDataIndexer

public OnePassDataIndexer(EventStream eventStream)
                   throws IOException
One argument constructor for DataIndexer which calls the two argument constructor assuming no cutoff.

Parameters:
eventStream - An Event[] which contains the a list of all the Events seen in the training data.
Throws:
IOException

OnePassDataIndexer

public OnePassDataIndexer(EventStream eventStream,
                          int cutoff)
                   throws IOException
Throws:
IOException

OnePassDataIndexer

public OnePassDataIndexer(EventStream eventStream,
                          int cutoff,
                          boolean sort)
                   throws IOException
Two argument constructor for DataIndexer.

Parameters:
eventStream - An Event[] which contains the a list of all the Events seen in the training data.
cutoff - The minimum number of times a predicate must have been observed in order to be included in the model.
Throws:
IOException


Copyright © 2011 The Apache Software Foundation. All Rights Reserved.