|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgov.sandia.cognition.framework.concurrent.AbstractConcurrentCognitiveModule
gov.sandia.cognition.framework.learning.EvaluatorBasedCognitiveModule<InputType,OutputType>
InputType - Input type of the embedded EvaluatorOutputType - Output type of the embedded Evaluatorpublic class EvaluatorBasedCognitiveModule<InputType,OutputType>
The EvaluatorBasedCognitiveModule implements a CognitiveModule that wraps an Evaluator object.
| Field Summary | |
|---|---|
static String |
DEFAULT_NAME
Default name given to modules of this type |
protected InputType |
input
A place to temporarily store the input read in by a call to readState; this temporary store is blown away as soon as it used by evaluate, because we NEVER retain state interally across module update cycles |
protected OutputType |
output
A place to temporarily store the output generated by a call to evaluate; this temporary store is blown away as soon as it used by evaluate, because we NEVER retain state interally across module update cycles |
| Constructor Summary | |
|---|---|
EvaluatorBasedCognitiveModule(CognitiveModel model,
EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> settings,
String name)
Creates a new instance of EvaluatorBasedCognitiveModule. |
|
| Method Summary | |
|---|---|
void |
evaluate()
|
gov.sandia.cognition.evaluator.Evaluator<? super InputType,? extends OutputType> |
getEvaluator()
Gets the underlying evaluator that is being wrapped in this module. |
CogxelConverter<InputType> |
getInputConverter()
Gets the input converter that is used to map from Cogxels to the InputType. |
String |
getName()
|
CogxelConverter<OutputType> |
getOutputConverter()
Gets the output converter that is used to map from the OutputType to Cogxels. |
EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> |
getSettings()
|
CognitiveModuleState |
initializeState(CognitiveModelState modelState)
|
void |
readState(CognitiveModelState modelState,
CognitiveModuleState previousModuleState)
|
void |
setName(String name)
Sets the name of the module |
protected void |
setSettings(EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> settings)
Sets the settings of the module. |
CognitiveModuleState |
writeState(CognitiveModelState modelState)
|
| Methods inherited from class gov.sandia.cognition.framework.concurrent.AbstractConcurrentCognitiveModule |
|---|
update |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected InputType input
protected OutputType output
public static final String DEFAULT_NAME
| Constructor Detail |
|---|
public EvaluatorBasedCognitiveModule(CognitiveModel model,
EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> settings,
String name)
model - The model to create the module for.settings - The settings of the module.name - High-level name of this module| Method Detail |
|---|
public CognitiveModuleState initializeState(CognitiveModelState modelState)
modelState -
public void readState(CognitiveModelState modelState,
CognitiveModuleState previousModuleState)
modelState - previousModuleState - public void evaluate()
public CognitiveModuleState writeState(CognitiveModelState modelState)
modelState -
public String getName()
public void setName(String name)
name - Name to assign to the modulepublic EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> getSettings()
protected void setSettings(EvaluatorBasedCognitiveModuleSettings<InputType,OutputType> settings)
settings - The module's settings.public gov.sandia.cognition.evaluator.Evaluator<? super InputType,? extends OutputType> getEvaluator()
public CogxelConverter<InputType> getInputConverter()
public CogxelConverter<OutputType> getOutputConverter()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||