edu.cmu.minorthird.classify
Class StackedDatasetClassifierTeacher

java.lang.Object
  extended by edu.cmu.minorthird.classify.ClassifierTeacher
      extended by edu.cmu.minorthird.classify.StackedClassifierTeacher
          extended by edu.cmu.minorthird.classify.StackedDatasetClassifierTeacher

public class StackedDatasetClassifierTeacher
extends StackedClassifierTeacher

Trains a StackedClassifierLearner using the information in a labeled relational Dataset.

Author:
Zhenzhen Kou

Constructor Summary
StackedDatasetClassifierTeacher(Dataset dataset)
           
StackedDatasetClassifierTeacher(Dataset dataset, boolean activeLearning)
           
 
Method Summary
 java.util.Iterator<Example> examplePool()
          Labeled instances that will be sent to the learner via a call to addExample().
 java.util.Map<java.lang.String,java.util.Set<java.lang.String>> getAggregators()
          The Aggregators for stacked graphical learning
 java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.util.Set<java.lang.String>>> getLinksMap()
          The linkMaps for stacked graphical learning
 boolean hasAnswers()
          Return true if this teacher can answer more queries.
 java.util.Iterator<Instance> instancePool()
          Unlabeled instances, which will be provided to the learner via setInstancePool().
 Example labelInstance(Instance query)
          Label an Instance chosen by the learner.
static void main(java.lang.String[] argv)
           
 ExampleSchema schema()
          The set of classes that will be used.
 
Methods inherited from class edu.cmu.minorthird.classify.StackedClassifierTeacher
trainStacked
 
Methods inherited from class edu.cmu.minorthird.classify.ClassifierTeacher
train
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StackedDatasetClassifierTeacher

public StackedDatasetClassifierTeacher(Dataset dataset)

StackedDatasetClassifierTeacher

public StackedDatasetClassifierTeacher(Dataset dataset,
                                       boolean activeLearning)
Parameters:
activeLearning - if true, all learning is active - ie nothing is pushed at the learner, everything must be 'pulled' via queries. if false, all examples fron the dataset are 'pushed' at the learner via addExample.
Method Detail

schema

public ExampleSchema schema()
Description copied from class: ClassifierTeacher
The set of classes that will be used.

Specified by:
schema in class ClassifierTeacher

getLinksMap

public java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.util.Set<java.lang.String>>> getLinksMap()
Description copied from class: StackedClassifierTeacher
The linkMaps for stacked graphical learning

Specified by:
getLinksMap in class StackedClassifierTeacher

getAggregators

public java.util.Map<java.lang.String,java.util.Set<java.lang.String>> getAggregators()
Description copied from class: StackedClassifierTeacher
The Aggregators for stacked graphical learning

Specified by:
getAggregators in class StackedClassifierTeacher

examplePool

public java.util.Iterator<Example> examplePool()
Description copied from class: ClassifierTeacher
Labeled instances that will be sent to the learner via a call to addExample().

Specified by:
examplePool in class ClassifierTeacher

instancePool

public java.util.Iterator<Instance> instancePool()
Description copied from class: ClassifierTeacher
Unlabeled instances, which will be provided to the learner via setInstancePool(). These can be used for semi-supervised learner, or to form queries for active learning. .

Specified by:
instancePool in class ClassifierTeacher

labelInstance

public Example labelInstance(Instance query)
Description copied from class: ClassifierTeacher
Label an Instance chosen by the learner. Return null if the query can't be answered, otherwise return a labeled version of the instance (an Example).

Specified by:
labelInstance in class ClassifierTeacher

hasAnswers

public boolean hasAnswers()
Description copied from class: ClassifierTeacher
Return true if this teacher can answer more queries.

Specified by:
hasAnswers in class ClassifierTeacher

main

public static void main(java.lang.String[] argv)