#include <PatternManager.h>
Public Member Functions | |
| PatternManager (DBInterface *netDBInterface, DBInterface *pattDBInterface, unsigned int neurGrpID, unsigned int patternGrpID) | |
| ~PatternManager () | |
| void | fireNeurons () |
| void | loadPatternData () |
| void | setNeuronArray (Neuron **neurArr, int neurArrLen) |
Private Member Functions | |
| PatternManager (const PatternManager &) | |
| PatternManager | operator= (const PatternManager &) |
| void | fillPatternArray (string &patternString) |
| void | loadPatternGroup (unsigned int pattGrpID) |
| void | unloadPatternGroup () |
Private Attributes | |
| DBInterface * | networkDBInterface |
| DBInterface * | patternDBInterface |
| mysqlpp::Query * | patternQuery |
| mysqlpp::Connection * | patternConnection |
| mysqlpp::ResUse * | patternResults |
| unsigned int | neuronGrpID |
| bool | patternLoaded |
| unsigned int | patternGrpID |
| unsigned int | patternType |
| unsigned int | neuronGrpWidth |
| unsigned int | neuronGrpLength |
| int * | patternArray |
| int | patternArrayLength |
| Neuron ** | neuronArray |
| int | numberOfNeurons |
| bool | rotatePattern |
| vector< unsigned int > | patternBuffer [NUMBER_OF_DELAY_VALUES] |
| unsigned int | bufferCounter |
Temporal patterns are applied once and then a new pattern is applied after a number of timesteps. Fixed patterns are applied every time step.
Definition at line 47 of file PatternManager.h.
|
||||||||||||||||||||
|
Constructor. Definition at line 38 of file PatternManager.cpp. References bufferCounter, loadPatternGroup(), networkDBInterface, neuronGrpID, patternConnection, patternDBInterface, patternGrpID, patternLoaded, patternQuery, rotatePattern, and SpikeStreamSimulation::systemError(). |
|
|
Destructor. Definition at line 74 of file PatternManager.cpp. References patternConnection, patternLoaded, patternQuery, and unloadPatternGroup(). |
|
|
Declare copy constructor private so it cannot be used inadvertently. |
|
|
Loads the supplied patternArray with the values from the patternString. These are separated with commas. Definition at line 208 of file PatternManager.cpp. References patternArray, patternArrayLength, and SpikeStreamSimulation::systemError(). Referenced by loadPatternData(). |
|
|
Fires neurons in the neuron array according to the pattern. Definition at line 96 of file PatternManager.cpp. References bufferCounter, Neuron::fireNeuron(), neuronArray, patternBuffer, patternLoaded, and patternType. Referenced by SpikeStreamSimulation::loadSimulationData(), and SpikeStreamSimulation::sendSpikeMessages(). |
|
|
Loads pattern data from the database into the pattern buffer. This data will change the firing pattern when fireNeurons() is called. Definition at line 119 of file PatternManager.cpp. References bufferCounter, fillPatternArray(), neuronGrpLength, neuronGrpWidth, patternArray, patternBuffer, patternLoaded, patternResults, patternType, rotatePattern, SpikeStreamSimulation::systemError(), and unloadPatternGroup(). Referenced by loadPatternGroup(), and SpikeStreamSimulation::sendSpikeMessages(). |
|
|
Loads up a set of patterns from the database ready to be played back as the simulation progresses. Definition at line 264 of file PatternManager.cpp. References loadPatternData(), networkDBInterface, neuronGrpID, neuronGrpLength, neuronGrpWidth, patternArray, patternArrayLength, patternDBInterface, patternGrpID, patternLoaded, patternQuery, patternResults, patternType, rotatePattern, SpikeStreamSimulation::systemError(), and unloadPatternGroup(). Referenced by PatternManager(). |
|
|
Declare assignment private so it cannot be used. |
|
||||||||||||
|
Passes a reference to the array of neurons held in SpikeStreamSimulation. Definition at line 196 of file PatternManager.cpp. References neuronArray, and numberOfNeurons. Referenced by SpikeStreamSimulation::loadSimulationData(). |
|
|
Unloads the pattern. Definition at line 360 of file PatternManager.cpp. References patternArray, patternBuffer, patternGrpID, patternLoaded, and patternResults. Referenced by loadPatternData(), loadPatternGroup(), and ~PatternManager(). |
|
|
The current position in the pattern buffer. Definition at line 114 of file PatternManager.h. Referenced by fireNeurons(), loadPatternData(), and PatternManager(). |
|
|
Definition at line 60 of file PatternManager.h. Referenced by loadPatternGroup(), and PatternManager(). |
|
|
Reference to the neuron array in SpikeStreamSimulation. Definition at line 101 of file PatternManager.h. Referenced by fireNeurons(), and setNeuronArray(). |
|
|
The id of the neuron group that is being simulated by this task. Definition at line 76 of file PatternManager.h. Referenced by loadPatternGroup(), and PatternManager(). |
|
|
Length of the neuron group. Definition at line 91 of file PatternManager.h. Referenced by loadPatternData(), and loadPatternGroup(). |
|
|
Width of the neuron group. Definition at line 88 of file PatternManager.h. Referenced by loadPatternData(), and loadPatternGroup(). |
|
|
Length of the neuron array in SpikeStreamSimulation. Definition at line 104 of file PatternManager.h. Referenced by setNeuronArray(). |
|
|
Array into which the pattern data is loaded from the database by extracting it from a string. Definition at line 95 of file PatternManager.h. Referenced by fillPatternArray(), loadPatternData(), loadPatternGroup(), and unloadPatternGroup(). |
|
|
The length of the pattern array. Definition at line 98 of file PatternManager.h. Referenced by fillPatternArray(), and loadPatternGroup(). |
|
|
Holds the neurons that need to be fired at each time point. Definition at line 111 of file PatternManager.h. Referenced by fireNeurons(), loadPatternData(), and unloadPatternGroup(). |
|
|
Need a new connection to the database to be able to use ResUse for the pattern query. Definition at line 69 of file PatternManager.h. Referenced by PatternManager(), and ~PatternManager(). |
|
|
Definition at line 61 of file PatternManager.h. Referenced by loadPatternGroup(), and PatternManager(). |
|
|
Current pattern type. Definition at line 82 of file PatternManager.h. Referenced by loadPatternGroup(), PatternManager(), and unloadPatternGroup(). |
|
|
Records when a pattern has been loaded. Definition at line 79 of file PatternManager.h. Referenced by fireNeurons(), loadPatternData(), loadPatternGroup(), PatternManager(), unloadPatternGroup(), and ~PatternManager(). |
|
|
Store references to query class to enable us to move progressively through the pattern in the database. Definition at line 65 of file PatternManager.h. Referenced by loadPatternGroup(), PatternManager(), and ~PatternManager(). |
|
|
Store references to result class to enable us to move progressively through the pattern in the database. Definition at line 73 of file PatternManager.h. Referenced by loadPatternData(), loadPatternGroup(), and unloadPatternGroup(). |
|
|
Current pattern type. Definition at line 85 of file PatternManager.h. Referenced by fireNeurons(), loadPatternData(), and loadPatternGroup(). |
|
|
Is the pattern rotated wrt the neuron group or not?. Definition at line 108 of file PatternManager.h. Referenced by loadPatternData(), loadPatternGroup(), and PatternManager(). |
1.4.4