InputType
- Input type of the embedded Evaluator.OutputType
- Output type of the embedded Evaluator.LearningDataType
- Data type used to create the training set,
for example "Vector" or "InputOutputPairpublic class EvaluatorBasedCognitiveModuleFactoryLearner<InputType,OutputType,LearningDataType> extends AbstractCloneableSerializable implements CognitiveModuleFactoryLearner
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEFAULT_NAME
Default name for this module
|
Constructor and Description |
---|
EvaluatorBasedCognitiveModuleFactoryLearner()
Creates a new instance of CognitiveModuleFactoryEvaluatorLearner.
|
EvaluatorBasedCognitiveModuleFactoryLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> learner,
java.lang.String name,
CogxelConverter<InputType> inputConverter,
CogxelConverter<OutputType> outputConverter,
CogxelConverter<LearningDataType> learningDataConverter)
Creates a new instance of CognitiveModuleFactoryEvaluatorLearner.
|
EvaluatorBasedCognitiveModuleFactoryLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<InputType,OutputType>> learner,
java.lang.String name)
Creates a new instance of CognitiveModuleFactoryEvaluatorLearner.
|
EvaluatorBasedCognitiveModuleFactoryLearner(EvaluatorBasedCognitiveModuleFactoryLearner<InputType,OutputType,LearningDataType> other)
Creates a new copy of a of CognitiveModuleFactoryEvaluatorLearner.
|
Modifier and Type | Method and Description |
---|---|
EvaluatorBasedCognitiveModuleFactoryLearner<InputType,OutputType,LearningDataType> |
clone()
Creates a copy of this EvaluatorBasedCognitiveModuleFactoryLearner.
|
CogxelConverter<InputType> |
getInputConverter()
Gets the CogxelConverter used to convert from a CogxelState to InputType.
|
BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> |
getLearner()
Gets the learner used to create the Evaluator for the module.
|
CogxelConverter<LearningDataType> |
getLearningDataConverter()
Gets the CogxelConverter used to convert from a CogxelState to
LearningDataType.
|
java.lang.String |
getName()
Getter for name
|
CogxelConverter<OutputType> |
getOutputConverter()
Gets the CogxelConverter used to convert OutputType to a CogxelState.
|
EvaluatorBasedCognitiveModuleFactory<InputType,OutputType> |
learn(CognitiveModel model,
java.util.Collection<? extends java.util.Collection<? extends CognitiveModelInput>> datasets)
Learns a new EvaluatorBasedCognitiveModuleFactory
|
void |
setInputConverter(CogxelConverter<InputType> inputConverter)
Sets the CogxelConverter used to convert from a CogxelState to InputType.
|
void |
setLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> learner)
Sets the learner used to create the Evaluator for the module.
|
void |
setLearningDataConverter(CogxelConverter<LearningDataType> learningDataConverter)
Sets the CogxelConverter used to convert from a CogxelState to
LearningDataType.
|
void |
setName(java.lang.String name)
Setter for name
|
void |
setOutputConverter(CogxelConverter<OutputType> outputConverter)
Sets the CogxelConverter used to convert OutputType to a CogxelState.
|
public static final java.lang.String DEFAULT_NAME
public EvaluatorBasedCognitiveModuleFactoryLearner()
public EvaluatorBasedCognitiveModuleFactoryLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<InputType,OutputType>> learner, java.lang.String name)
learner
- The learner to use to learn the evaluator.name
- High-level name of the modulepublic EvaluatorBasedCognitiveModuleFactoryLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> learner, java.lang.String name, CogxelConverter<InputType> inputConverter, CogxelConverter<OutputType> outputConverter, CogxelConverter<LearningDataType> learningDataConverter)
learner
- The learner to use to learn the evaluator.name
- High-level name of the moduleinputConverter
- The CogxelConverter used to convert from a
CogxelState to InputType.outputConverter
- The CogxelConverter used to convert OutputType
to a CogxelState.learningDataConverter
- The CogxelConverter used to convert from
a CogxelState to LearningDataType.public EvaluatorBasedCognitiveModuleFactoryLearner(EvaluatorBasedCognitiveModuleFactoryLearner<InputType,OutputType,LearningDataType> other)
other
- The other CognitiveModuleFactoryEvaluatorLearner to copy.public EvaluatorBasedCognitiveModuleFactoryLearner<InputType,OutputType,LearningDataType> clone()
clone
in interface CloneableSerializable
clone
in class AbstractCloneableSerializable
public EvaluatorBasedCognitiveModuleFactory<InputType,OutputType> learn(CognitiveModel model, java.util.Collection<? extends java.util.Collection<? extends CognitiveModelInput>> datasets)
learn
in interface CognitiveModuleFactoryLearner
model
- The model to learn the module factory for.datasets
- The datasets to use to learn the module factory.public BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> getLearner()
public void setLearner(BatchLearner<? super java.util.Collection<LearningDataType>,? extends Evaluator<? super InputType,? extends OutputType>> learner)
learner
- The learner used to create the Evaluator for the module.public CogxelConverter<InputType> getInputConverter()
public void setInputConverter(CogxelConverter<InputType> inputConverter)
inputConverter
- The CogxelConverter used to convert from a
CogxelState to InputType.public CogxelConverter<OutputType> getOutputConverter()
public void setOutputConverter(CogxelConverter<OutputType> outputConverter)
outputConverter
- The CogxelConverter used to convert OutputType
to a CogxelState.public CogxelConverter<LearningDataType> getLearningDataConverter()
public void setLearningDataConverter(CogxelConverter<LearningDataType> learningDataConverter)
learningDataConverter
- The CogxelConverter used to convert from
a CogxelState to LearningDataType.public java.lang.String getName()
public void setName(java.lang.String name)
name
- Human-readable name for this module