tasksimulators.newsimu.XOR
Class AgentXOR

java.lang.Object
  extended byclarion.system.TaskAgent
      extended bytasksimulators.newsimu.XOR.AgentXOR

public class AgentXOR
extends TaskAgent


Field Summary
 
Fields inherited from class clarion.system.TaskAgent
activeAmnIdx, clarion, curNacsInput, curSensoryInput, desiredOutput, global, learningTestOn, nacsResults, reinforcements, taskClarion
 
Constructor Summary
AgentXOR()
           
AgentXOR(Global g)
           
 
Method Summary
 int determineAmnNet(int netIdx, short[][][] action)
          Determines which AMN will be used given current action.
 void getOutput(java.lang.Object arr)
          Returns the output of current step.
 boolean isControlNacsAction(int netIdx, short[] chosenAction)
           
 void performAction(int netIdx, short[][][] action)
          This determines the action to be performed at each step.
 void run()
          simulates one step in the agent's behavior for this experiment.
 void setRetrievalResults(int netIdx, GKSChunk[] results)
          send the retrieval results from NACS to ACS components.
 void setSensoryInput(short[] inputs)
           
 
Methods inherited from class clarion.system.TaskAgent
getActiveAmnIdx, getCurDesiredOutput, getCurNacsInput, getCurSensoryInput, getFixRules, getIrlRules, getRerRules, isInLearningTest, reinit, saveOutput, setLearningTest
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AgentXOR

public AgentXOR()

AgentXOR

public AgentXOR(Global g)
Method Detail

setSensoryInput

public void setSensoryInput(short[] inputs)

isControlNacsAction

public boolean isControlNacsAction(int netIdx,
                                   short[] chosenAction)

getOutput

public void getOutput(java.lang.Object arr)
Description copied from class: TaskAgent
Returns the output of current step.

Specified by:
getOutput in class TaskAgent
Parameters:
arr - the array to be filled in with current output.

determineAmnNet

public int determineAmnNet(int netIdx,
                           short[][][] action)
Description copied from class: TaskAgent
Determines which AMN will be used given current action.

Specified by:
determineAmnNet in class TaskAgent
Parameters:
netIdx - the ACS network index.
action - the selected actions by ACS networks.
Returns:
the AMN network index.

setRetrievalResults

public void setRetrievalResults(int netIdx,
                                GKSChunk[] results)
Description copied from class: TaskAgent
send the retrieval results from NACS to ACS components.

Specified by:
setRetrievalResults in class TaskAgent
Parameters:
netIdx - the ACS network index.
results - retrieval results from NACS

performAction

public void performAction(int netIdx,
                          short[][][] action)
This determines the action to be performed at each step. For the XOR task, the only "action" is to set the output correctly.

Overrides:
performAction in class TaskAgent
Parameters:
netIdx - the ACS network index
action - the selected action from the specified ACS network.

run

public void run()
simulates one step in the agent's behavior for this experiment.

Specified by:
run in class TaskAgent