public class OnePassRealValueDataIndexer extends OnePassDataIndexer
contexts, numTimesEventsSeen, outcomeLabels, outcomeList, predCounts, predLabels| Constructor and Description |
|---|
OnePassRealValueDataIndexer(EventStream eventStream,
int cutoff)
Two argument constructor for DataIndexer.
|
OnePassRealValueDataIndexer(EventStream eventStream,
int cutoff,
boolean sort) |
| Modifier and Type | Method and Description |
|---|---|
float[][] |
getValues()
Returns the values associated with each event context or null if integer values are to be used.
|
protected List |
index(LinkedList<Event> events,
Map<String,Integer> predicateIndex) |
protected int |
sortAndMerge(List<ComparableEvent> eventsToCompare,
boolean sort)
Sorts and uniques the array of comparable events and return the number of unique events.
|
getContexts, getNumEvents, getNumTimesEventsSeen, getOutcomeLabels, getOutcomeList, getPredCounts, getPredLabels, toIndexedStringArray, updatepublic OnePassRealValueDataIndexer(EventStream eventStream, int cutoff, boolean sort) throws IOException
IOExceptionpublic OnePassRealValueDataIndexer(EventStream eventStream, int cutoff) throws IOException
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.IOExceptionpublic float[][] getValues()
DataIndexergetValues in interface DataIndexergetValues in class AbstractDataIndexerprotected int sortAndMerge(List<ComparableEvent> eventsToCompare, boolean sort)
AbstractDataIndexersortAndMerge in class AbstractDataIndexereventsToCompare - a ComparableEvent[] valueprotected List index(LinkedList<Event> events, Map<String,Integer> predicateIndex)
index in class OnePassDataIndexerCopyright © 2016 The Apache Software Foundation. All rights reserved.