Klasse AbstractDataIndexer

java.lang.Object
opennlp.tools.ml.model.AbstractDataIndexer
Alle implementierten Schnittstellen:
DataIndexer
Bekannte direkte Unterklassen:
OnePassDataIndexer, TwoPassDataIndexer

public abstract class AbstractDataIndexer extends Object implements DataIndexer
Abstract DataIndexer implementation for collecting event and context counts used in training.
Siehe auch:
  • Felddetails

  • Konstruktordetails

    • AbstractDataIndexer

      public AbstractDataIndexer()
  • Methodendetails

    • init

      public void init(TrainingParameters indexingParameters, Map<String,String> reportMap)
      Sets parameters used during the data indexing.
      Angegeben von:
      init in Schnittstelle DataIndexer
      Parameter:
      indexingParameters - The TrainingParameters to be used.
      reportMap - The Map used for reporting.
    • getContexts

      public int[][] getContexts()
      Angegeben von:
      getContexts in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves a 2-dimensional array whose first dimension is the event index and array this refers to contains the contexts for that event.
    • getNumTimesEventsSeen

      public int[] getNumTimesEventsSeen()
      Angegeben von:
      getNumTimesEventsSeen in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves an array indexed by the event index indicating the number of times a particular event was seen.
    • getOutcomeList

      public int[] getOutcomeList()
      Angegeben von:
      getOutcomeList in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves an array indicating the outcome index for each event.
    • getPredLabels

      public String[] getPredLabels()
      Angegeben von:
      getPredLabels in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves an array of predicate/context names indexed by context index. These indices are the value of the array returned by DataIndexer.getContexts().
    • getOutcomeLabels

      public String[] getOutcomeLabels()
      Angegeben von:
      getOutcomeLabels in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves an array of outcome names indexed by outcome index.
    • getPredCounts

      public int[] getPredCounts()
      Angegeben von:
      getPredCounts in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves an array of the count of each predicate in the events.
    • getNumEvents

      public int getNumEvents()
      Angegeben von:
      getNumEvents in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves the number of total events indexed.
    • getValues

      public float[][] getValues()
      Angegeben von:
      getValues in Schnittstelle DataIndexer
      Gibt zurück:
      Retrieves the values associated with each event context or null if integer values are to be used.