49 class ConnectionMonitorCore;
465 void printSparse(
int neurPostId=
ALL,
int maxConn=100,
int connPerLine=4);
503 ConnectionMonitorCore* connMonCorePtr_;
double getPercentWeightsWithValue(double value)
Returns the percentage of weights in the connection with a particular value.
int getNumWeightsInRange(double minValue, double maxValue)
Returns the number of weights in the connection whose values are within some range (inclusive) ...
std::vector< std::vector< float > > takeSnapshot()
Takes a snapshot of the current weight state.
int getNumNeuronsPost()
Returns the number of post-synaptic neurons.
#define ALL
CARLsim common definitions.
ConnectionMonitor(ConnectionMonitorCore *connMonCorePtr)
ConnectionMonitor constructor.
int getNumWeightsWithValue(double value)
Returns the number of weights in the connection with a particular value.
void setUpdateTimeIntervalSec(int intervalSec)
Sets the time interval (seconds) for writing snapshots to file.
~ConnectionMonitor()
ConnectionMonitor destructor.
int64_t getTimeMsCurrentSnapshot()
Returns the timestamp of the current snapshot (ms since beginning of simulation)
void print()
Prints the current weight state as a 2D matrix (pre x post)
void printSparse(int neurPostId=ALL, int maxConn=100, int connPerLine=4)
Prints the current weight state as a sparse list of weights.
int getFanIn(int neurPostId)
Returns the number of incoming synapses for a specific post-synaptic neuron.
std::vector< std::vector< float > > calcWeightChanges()
Reports the weight changes since the last snapshot in a 2D weight matrix (pre x post) ...
short int getConnectId()
Returns the connection ID that this ConnectionMonitor is managing.
int getNumNeuronsPre()
Returns the number of pre-synaptic neurons.
double getPercentWeightsInRange(double minValue, double maxValue)
Returns the percentage of weights whose values are within some range (inclusive)
int getNumSynapses()
Returns the number of allocated synapses.
int64_t getTimeMsSinceLastSnapshot()
Returns the timestamp difference of the current and last snapshot.
double getMaxWeight(bool getCurrent=false)
Returns the max weight in the connection.
int64_t getTimeMsLastSnapshot()
Returns the timestamp of the last snapshot (ms since beginning of simulation)
double getTotalAbsWeightChange()
Returns the absolute sum of all the weight changes since the last snapshot.
int getFanOut(int neurPreId)
Returns the number of outgoing synapses for a specific pre-synaptic neuron.
double getPercentWeightsChanged(double minAbsChanged=1e-5)
Returns the percentage of weights that have changed since the last snapshot.
int getNumWeightsChanged(double minAbsChanged=1e-5)
Returns the number of weights that have changed since the last snapshot.
double getMinWeight(bool getCurrent=false)
Returns the min weight in the connection.