Auryn simulator  v0.8.1-206-gb56e451
Plastic Spiking Neural Network Simulator
Public Member Functions | Public Attributes | List of all members
auryn::STPConnection Class Reference

This class implements short term plasticity according to the Tsodyks-Markram synapse. More...

#include <STPConnection.h>

Inheritance diagram for auryn::STPConnection:
Inheritance graph
[legend]
Collaboration diagram for auryn::STPConnection:
Collaboration graph
[legend]

Public Member Functions

 STPConnection (const char *filename)
 
 STPConnection (NeuronID rows, NeuronID cols)
 
 STPConnection (SpikingGroup *source, NeuronGroup *destination, TransmitterType transmitter=GLUT)
 
 STPConnection (SpikingGroup *source, NeuronGroup *destination, const char *filename, TransmitterType transmitter=GLUT)
 
 STPConnection (SpikingGroup *source, NeuronGroup *destination, AurynWeight weight, AurynFloat sparseness=0.05, TransmitterType transmitter=GLUT, string name="STPConnection")
 
void set_tau_d (AurynFloat taud)
 
void set_tau_f (AurynFloat tauf)
 
void set_ujump (AurynFloat r)
 
void clear ()
 Clear. More...
 
void clone_parameters (STPConnection *con)
 Clone parameters. More...
 
virtual ~STPConnection ()
 
virtual void propagate ()
 
void push_attributes ()
 
void evolve ()
 
- Public Member Functions inherited from auryn::SparseConnection
 SparseConnection ()
 Empty constructor which should not be used – TODO should be deprecated at some point. More...
 
 SparseConnection (const char *filename)
 Load from wmat file constructor which should not be used – TODO should be deprecated at some point. More...
 
 SparseConnection (NeuronID rows, NeuronID cols)
 Deprecated constructor for manual filling. More...
 
 SparseConnection (SpikingGroup *source, NeuronGroup *destination, const char *filename, TransmitterType transmitter=GLUT)
 Deprecated constructor for loading from file. More...
 
 SparseConnection (SpikingGroup *source, NeuronGroup *destination, TransmitterType transmitter=GLUT, string name="SparseConnection")
 Constructor for manual filling. More...
 
 SparseConnection (SpikingGroup *source, NeuronGroup *destination, AurynWeight weight, AurynDouble sparseness=0.05, TransmitterType transmitter=GLUT, string name="SparseConnection")
 Default constructor which sets up a random sparse matrix with fixed weight between the source and destination group. More...
 
 SparseConnection (SpikingGroup *source, NeuronGroup *destination, SparseConnection *con, string name="SparseConnection")
 This constructor tries to clone a connection by guessing all parameters except source and destination from another connection instance. More...
 
 SparseConnection (SpikingGroup *source, NeuronGroup *destination, AurynWeight weight, AurynDouble sparseness, NeuronID lo_row, NeuronID hi_row, NeuronID lo_col, NeuronID hi_col, TransmitterType transmitter=GLUT)
 Sparse block constructor. More...
 
virtual ~SparseConnection ()
 The default destructor. More...
 
void allocate_manually (AurynLong expected_size)
 Is used whenever memory has to be allocated manually. Automatically adjusts for number of ranks and for security margin. More...
 
AurynLong estimate_required_nonzero_entires (AurynLong nonzero, double sigma=5.)
 This function estimates the required size of the nonzero entry buffer. More...
 
void seed (NeuronID randomseed)
 This function seeds the pseudo random number generator for all random fill operatios. More...
 
virtual AurynWeight get (NeuronID i, NeuronID j)
 Returns weight value of a given element if it exists. More...
 
virtual AurynWeightget_ptr (NeuronID i, NeuronID j)
 Returns pointer to given weight element if it exists. Returns NULL if element does not exist. More...
 
virtual AurynWeight get_data (NeuronID i)
 Returns weight value of a given element referenced by index in the data array. More...
 
virtual void set_data (NeuronID i, AurynWeight value)
 Sets weight value of a given element referenced by its index in the data array. More...
 
virtual void set (NeuronID i, NeuronID j, AurynWeight value)
 Sets a single connection to value if it exists. More...
 
virtual void set (std::vector< neuron_pair > element_list, AurynWeight value)
 Sets a list of connection to value if they exists. More...
 
void random_data (AurynWeight mean, AurynWeight sigma)
 Synonym for random_data. More...
 
void random_data_normal (AurynWeight mean, AurynWeight sigma)
 Set weights of all existing connections randomly using a normal distrubtion. More...
 
void random_data_lognormal (AurynWeight m, AurynWeight s)
 Set weights of all existing connections randomly using a lognormal distribution. More...
 
void init_random_binary (AurynFloat prob=0.5, AurynWeight wlo=0.0, AurynWeight whi=1.0)
 Initialize with random binary at wlo and whi. More...
 
void random_col_data (AurynWeight mean, AurynWeight sigma)
 Sets weights in cols to the same value drewn from a Gaussian distribution. More...
 
void set_block (NeuronID lo_row, NeuronID hi_row, NeuronID lo_col, NeuronID hi_col, AurynWeight weight)
 Sets all weights of existing connections in a block spanned by the first 4 parameters to the value given. More...
 
void scale_block (NeuronID lo_row, NeuronID hi_row, NeuronID lo_col, NeuronID hi_col, AurynWeight alpha)
 Scale all weights of existing connections in a block spanned by the first 4 parameters to the value given. More...
 
virtual void set_all (AurynWeight weight)
 Sets all weights of existing connections to the given value. More...
 
virtual void scale_all (AurynFloat value)
 Scales all weights in the weight matrix with the given value. More...
 
virtual void clip (AurynWeight lo, AurynWeight hi)
 Clip weights. More...
 
void set_upper_triangular (AurynWeight weight)
 Sets weights in a upper triangular matrix. More...
 
virtual void sparse_set_data (AurynDouble sparseness, AurynWeight value)
 Sets a sparse random subset of connection elements wight the given value. More...
 
void connect_random (AurynWeight weight=1.0, AurynDouble sparseness=0.05, bool skip_diag=false)
 Connect src and dst SpikingGroup and NeuronGroup randomly with given sparseness. More...
 
void connect_block_random (AurynWeight weight, AurynDouble sparseness, NeuronID lo_row, NeuronID hi_row, NeuronID lo_col, NeuronID hi_col, bool skip_diag=false)
 Underlying sparse fill method. More...
 
virtual void finalize ()
 Finalizes connection after random or manual initialization of the weights. More...
 
bool push_back (NeuronID i, NeuronID j, AurynWeight weight)
 Pushes a single element to the ComplexMatrix. More...
 
AurynLong get_nonzero ()
 Returns number of nonzero elements in this SparseConnection. More...
 
void put_pattern (type_pattern *pattern, AurynWeight strength, bool overwrite)
 Puts cell assembly to existing sparse weights. More...
 
void put_pattern (type_pattern *pattern1, type_pattern *pattern2, AurynWeight strength, bool overwrite)
 Puts cell assembly or synfire pattern to existing sparse weights. More...
 
void load_patterns (string filename, AurynWeight strength, int nb_max_patterns=10000, bool overwrite=false, bool chainmode=false)
 Reads first n patterns from a .pat file and adds them as Hebbian assemblies onto an existing weight matrix. More...
 
void load_pre_post_patterns (std::string pre_file, std::string post_file, AurynWeight strength, int nb_max_patterns=10000, bool overwrite=false)
 Reads patterns from two files and connects them. More...
 
void sanity_check ()
 Quick an dirty function that checks if all units on the local rank are connected. More...
 
virtual AurynDouble sum ()
 Computes sum of all weight elements in the Connection. More...
 
virtual void stats (AurynDouble &mean, AurynDouble &std)
 Computes mean and variance of weights in default weight matrix. More...
 
virtual void stats (AurynDouble &mean, AurynDouble &std, NeuronID zid)
 Computes mean and variance of weights for matrix state zid. More...
 
bool write_to_file (ForwardMatrix *m, string filename)
 Writes rank specific weight matrix on the same rank to a file. More...
 
virtual bool write_to_file (string filename)
 Writes rank specific default weight matrix on the same rank to a file. More...
 
virtual bool load_from_complete_file (string filename)
 Loads weight matrix from a single file. More...
 
virtual bool load_from_file (string filename)
 Loads weight matrix from Matrix Market (wmat) file. More...
 
bool load_from_file (ForwardMatrix *m, string filename, AurynLong data_size=0)
 Loads weight matrix from Matrix Market (wmat) file to specified weight matrix. More...
 
virtual void set_min_weight (AurynWeight minimum_weight)
 Sets minimum weight (for plastic connections). More...
 
AurynWeight get_min_weight ()
 Gets minimum weight (for plastic connections). More...
 
virtual void set_max_weight (AurynWeight maximum_weight)
 Sets maximum weight (for plastic connections). More...
 
AurynWeight get_max_weight ()
 Gets maximum weight (for plastic connections). More...
 
std::vector< neuron_pairget_block (NeuronID lo_row, NeuronID hi_row, NeuronID lo_col, NeuronID hi_col)
 Returns a vector of ConnectionsID of a block specified by the arguments. More...
 
std::vector< neuron_pairget_post_partners (NeuronID i)
 Returns a vector of ConnectionsID of postsynaptic parterns of neuron i. More...
 
std::vector< neuron_pairget_pre_partners (NeuronID j)
 Returns a vector of ConnectionsID of presynaptic parterns of neuron i. More...
 
- Public Member Functions inherited from auryn::Connection
 Connection ()
 
 Connection (NeuronID rows, NeuronID cols)
 
 Connection (SpikingGroup *source, NeuronGroup *destination, TransmitterType transmitter=GLUT, std::string name="Connection")
 
virtual ~Connection ()
 
void set_size (NeuronID i, NeuronID j)
 
void set_name (std::string name)
 Set name of connection. More...
 
std::string get_name ()
 Returns name of connection. More...
 
std::string get_file_name ()
 Extracts the class name of the connection from the file name. More...
 
std::string get_log_name ()
 Returns a string which is the combination of file and connection name for logging. More...
 
AurynStateVectorget_target_vector ()
 Returns target state vector if one is defined. More...
 
NeuronID get_m_rows ()
 Get number of rows (presynaptic) in connection. More...
 
NeuronID get_n_cols ()
 Get number of columns (postsynaptic) in connection. More...
 
TransmitterType get_transmitter ()
 Returns transmitter type. More...
 
void set_target (AurynWeight *ptr)
 Sets target state of this connection directly via a pointer. More...
 
void set_target (AurynStateVector *ptr)
 Sets target state of this connection directly via a StateVector. More...
 
void set_receptor (AurynStateVector *ptr)
 Same as set_target. More...
 
void set_transmitter (AurynStateVector *ptr)
 Same as set_target. More...
 
void set_transmitter (TransmitterType transmitter)
 Sets target state of this connection for a given receptor as one of Auryn's default transmitter types. More...
 
void set_receptor (string state_name)
 Sets target state of this connection directly the name of a state vector. More...
 
void set_target (string state_name)
 Same as set_receptor. More...
 
void set_transmitter (string state_name)
 Same as set_receptor, but DEPRECATED. More...
 
void set_source (SpikingGroup *source)
 Sets source SpikingGroup of this connection. More...
 
SpikingGroupget_source ()
 Returns pointer to the presynaptic group. More...
 
void set_destination (NeuronGroup *source)
 Sets destination SpikingGroup of this connection. More...
 
NeuronGroupget_destination ()
 Returns pointer to the postsynaptic group. More...
 
void conditional_propagate ()
 DEPRECATED. (Such connections should not be registered in the first place) Calls propagate only if the postsynaptic NeuronGroup exists on the local rank. More...
 
Traceget_pre_trace (const AurynDouble tau)
 Returns a pointer to a presynaptic trace object. More...
 
Traceget_post_trace (const AurynDouble tau)
 Returns a pointer to a postsynaptic trace object. More...
 
Traceget_post_state_trace (const string state_name, const AurynDouble tau, const AurynDouble jump_size=0.0)
 Returns a pointer to a postsynaptic state trace object. More...
 
void transmit (const NeuronID id, const AurynWeight amount)
 Default way to transmit a spike to a postsynaptic partner. More...
 
void targeted_transmit (SpikingGroup *target_group, AurynStateVector *target_state, const NeuronID id, const AurynWeight amount)
 Transmits a spike to a given target group and state. More...
 
void safe_transmit (NeuronID id, AurynWeight amount)
 Same as transmit but first checks if the target neuron exists and avoids segfaults that way (but it's also slower). More...
 
SpikeContainerget_pre_spikes ()
 Supplies pointer to SpikeContainer of all presynaptic spikes. More...
 
SpikeContainerget_post_spikes ()
 Returns pointer to SpikeContainer for postsynaptic spikes on this node. More...
 
void add_number_of_spike_attributes (int x)
 Set up spike delay to accomodate x additional spike attributes. More...
 
AurynFloat get_spike_attribute (const NeuronID i, const int attribute_id=0)
 Returns spike attribute belonging to the spike at position i in the get_spikes() SpikeContainer. More...
 

Public Attributes

double tau_d
 
double tau_f
 
double Ujump
 
- Public Attributes inherited from auryn::SparseConnection
bool patterns_ignore_gamma
 Switch that toggles for the load_patterns function whether or not to use the intensity (gamma) value. Default is false. More...
 
NeuronID patterns_every_pre
 The every_pre parameter allows to skip presynaptically over pattern IDs when loading patterns. Default is 1. This can be useful to when loading patterns into the exc->inh connections and there significantly less inhibitory cells than exc ones. More...
 
NeuronID patterns_every_post
 The every_post parameter allows to skip postsynaptically over pattern IDs when loading patterns. Default is 1. This can be useful to when loading patterns into the exc->inh connections and there significantly less inhibitory cells than exc ones. More...
 
bool wrap_patterns
 Switch that toggles the behavior when loading a pattern to wrap neuron IDs back onto existing cells via the modulo function. More...
 
ForwardMatrixw
 A pointer that points per default to the ComplexMatrix that stores the connectinos. More...
 
- Public Attributes inherited from auryn::Connection
SpikingGroupsrc
 Pointer to the source group of this connection. More...
 
NeuronGroupdst
 Pointer to the destination group of this connection. More...
 

Additional Inherited Members

- Protected Member Functions inherited from auryn::SparseConnection
void virtual_serialize (boost::archive::binary_oarchive &ar, const unsigned int version)
 
void virtual_serialize (boost::archive::binary_iarchive &ar, const unsigned int version)
 
void free ()
 
void allocate (AurynLong bufsize)
 
std::vector< type_patternload_pattern_file (string filename, int nb_max_patterns)
 Reads patterns from a .pat file and returns a vector with the patterns. More...
 
- Protected Member Functions inherited from auryn::Connection
void init (TransmitterType transmitter=GLUT)
 
- Protected Attributes inherited from auryn::SparseConnection
AurynWeight wmin
 
AurynWeight wmax
 
bool skip_diagonal
 
- Protected Attributes inherited from auryn::Connection
TransmitterType trans
 
AurynStateVectortarget_state_vector
 
AurynFloattarget
 A more direct reference on the first element of the target_state_vector. More...
 
NeuronID number_of_spike_attributes
 Number of spike attributes to expect with each spike transmitted through this connection. More...
 
NeuronID spike_attribute_offset
 Stores spike attribute offset in attribute array. More...
 
- Static Protected Attributes inherited from auryn::SparseConnection
static boost::mt19937 sparse_connection_gen = boost::mt19937()
 

Detailed Description

This class implements short term plasticity according to the Tsodyks-Markram synapse.

This class implements the short-term plasticity model following Markram, H., Wang, Y., Tsodyks, M., 1998. Differential signaling via the same axon of neocortical pyramidal neurons. Proc Natl Acad Sci U S A 95, 5323–5328.

also see Mongillo, G., Barak, O., Tsodyks, M., 2008. Synaptic Theory of Working Memory. Science 319, 1543–1546. doi:10.1126/science.1150769

Constructor & Destructor Documentation

◆ STPConnection() [1/5]

STPConnection::STPConnection ( const char *  filename)

Minimal constructor for from file init – deprecated

Parameters
filenameFilename to load
52 : SparseConnection(filename)
53 {
54  init();
55 }
SparseConnection()
Empty constructor which should not be used – TODO should be deprecated at some point.

◆ STPConnection() [2/5]

STPConnection::STPConnection ( NeuronID  rows,
NeuronID  cols 
)

Minimal constructor to which leaves the connection uninitialized

Parameters
sourceThe presynaptic SpikingGroup
destinationthe postsynaptic NeuronGroup
73 : SparseConnection(rows,cols)
74 {
75  init();
76 }
SparseConnection()
Empty constructor which should not be used – TODO should be deprecated at some point.

◆ STPConnection() [3/5]

STPConnection::STPConnection ( SpikingGroup source,
NeuronGroup destination,
TransmitterType  transmitter = GLUT 
)

Default constructor to which leaves the connection uninitialized

Parameters
sourceThe presynaptic SpikingGroup
destinationthe postsynaptic NeuronGroup
transmitterThe transmitter type
59 : SparseConnection(source, destination, transmitter)
60 {
61 }
SparseConnection()
Empty constructor which should not be used – TODO should be deprecated at some point.

◆ STPConnection() [4/5]

STPConnection::STPConnection ( SpikingGroup source,
NeuronGroup destination,
const char *  filename,
TransmitterType  transmitter = GLUT 
)

Default constructor to initialize connection from file

Parameters
sourceThe presynaptic SpikingGroup
destinationthe postsynaptic NeuronGroup
filenameThe file to load the connectivity from upon initialization
transmitterThe transmitter type
nameThe connection name as it appears in debugging output
66 : SparseConnection(source, destination, filename, transmitter)
67 {
68  init();
69 }
SparseConnection()
Empty constructor which should not be used – TODO should be deprecated at some point.

◆ STPConnection() [5/5]

STPConnection::STPConnection ( SpikingGroup source,
NeuronGroup destination,
AurynWeight  weight,
AurynFloat  sparseness = 0.05,
TransmitterType  transmitter = GLUT,
std::string  name = "STPConnection" 
)

Default constructor to initialize connection with random sparse connectivity

Parameters
sourceThe presynaptic SpikingGroup
destinationthe postsynaptic NeuronGroup
weightThe default weight for connections
sparsenessThe probability of a connection for the sparse connectivity
transmitterThe transmitter type
nameThe connection name as it appears in debugging output
81 : SparseConnection(source,destination,weight,sparseness,transmitter, name)
82 {
83  init();
84 }
SparseConnection()
Empty constructor which should not be used – TODO should be deprecated at some point.
Here is the call graph for this function:

◆ ~STPConnection()

STPConnection::~STPConnection ( )
virtual

Default destructor.

98 {
99  free();
100 }

Member Function Documentation

◆ clear()

void STPConnection::clear ( )

Clear.

189 {
190  for (NeuronID i = 0; i < src->get_rank_size() ; i++)
191  {
192  auryn_vector_float_set (state_x, i, 1 ); // TODO
193  auryn_vector_float_set (state_u, i, Ujump );
194  }
195 }
NeuronID get_rank_size()
Returns the size on this rank.
Definition: SpikingGroup.h:450
double Ujump
Definition: STPConnection.h:62
SpikingGroup * src
Pointer to the source group of this connection.
Definition: Connection.h:108
unsigned int NeuronID
NeuronID is an unsigned integeger type used to index neurons in Auryn.
Definition: auryn_definitions.h:151
void auryn_vector_float_set(auryn_vector_float *v, const NeuronID i, AurynFloat x)
Definition: auryn_definitions.cpp:131
Here is the call graph for this function:

◆ clone_parameters()

void STPConnection::clone_parameters ( STPConnection con)

Clone parameters.

198 {
199  tau_d = con->tau_d;
200  tau_f = con->tau_f;
201  Ujump = con->Ujump;
202  clear();
203 }
double tau_d
Definition: STPConnection.h:60
double Ujump
Definition: STPConnection.h:62
double tau_f
Definition: STPConnection.h:61
void clear()
Clear.
Definition: STPConnection.cpp:188
Here is the call graph for this function:

◆ evolve()

void STPConnection::evolve ( )
virtual

Implements the connections evolve function (auryn internal use).

Reimplemented from auryn::Connection.

133 {
134  if ( src->evolve_locally() ) {
135  // dynamics of x
136  auryn_vector_float_set_all( state_temp, 1);
137  auryn_vector_float_saxpy(-1,state_x,state_temp);
138  auryn_vector_float_saxpy(auryn_timestep/tau_d,state_temp,state_x);
139 
140  // dynamics of u
141  auryn_vector_float_set_all( state_temp, Ujump);
142  auryn_vector_float_saxpy(-1,state_u,state_temp);
143  auryn_vector_float_saxpy(auryn_timestep/tau_f,state_temp,state_u);
144  }
145 }
double tau_d
Definition: STPConnection.h:60
void auryn_vector_float_set_all(auryn_vector_float *v, AurynFloat x)
Definition: auryn_definitions.cpp:115
double Ujump
Definition: STPConnection.h:62
SpikingGroup * src
Pointer to the source group of this connection.
Definition: Connection.h:108
bool evolve_locally()
Returns true if the calling instance has units which are integrated on the current rank...
Definition: SpikingGroup.cpp:323
void auryn_vector_float_saxpy(const float a, auryn_vector_float *x, auryn_vector_float *y)
Definition: auryn_definitions.cpp:79
double auryn_timestep
Simulation timestep in seconds.
Definition: auryn_definitions.cpp:31
double tau_f
Definition: STPConnection.h:61
Here is the call graph for this function:

◆ propagate()

void STPConnection::propagate ( )
virtual

Implements the connections propagate function (auryn internal use).

Reimplemented from auryn::SparseConnection.

148 {
149  if ( src->evolve_locally()) {
150  push_attributes(); // stuffs all attributes into the SpikeDelays for sync
151  }
152 
153  if ( dst->evolve_locally() ) { // necessary
154  NeuronID * ind = w->get_row_begin(0); // first element of index array
155  AurynWeight * data = w->get_data_begin(); // first element of data array
156 
157  // loop over spikes
158  for (NeuronID i = 0 ; i < src->get_spikes()->size() ; ++i ) {
159  // get spike at pos i in SpikeContainer
160  NeuronID spike = src->get_spikes()->at(i);
161 
162  // extract spike attribute from attribute stack;
163  AurynFloat attribute = get_spike_attribute(i);
164 
165  // loop over postsynaptic targets
166  for (NeuronID * c = w->get_row_begin(spike) ;
167  c != w->get_row_end(spike) ;
168  ++c ) {
169  AurynWeight value = data[c-ind] * attribute;
170  transmit( *c , value );
171  }
172  }
173  }
174 }
void push_attributes()
Definition: STPConnection.cpp:102
void transmit(const NeuronID id, const AurynWeight amount)
Default way to transmit a spike to a postsynaptic partner.
Definition: Connection.h:294
NeuronID * get_row_end(NeuronID i)
Definition: ComplexMatrix.h:952
ForwardMatrix * w
A pointer that points per default to the ComplexMatrix that stores the connectinos.
Definition: SparseConnection.h:147
SpikeContainer * get_spikes()
Returns pointer to a spike container that contains spikes which arrive in this timestep from all neur...
Definition: SpikingGroup.cpp:245
AurynFloat AurynWeight
Unit of synaptic weights.
Definition: auryn_definitions.h:159
SpikingGroup * src
Pointer to the source group of this connection.
Definition: Connection.h:108
NeuronGroup * dst
Pointer to the destination group of this connection.
Definition: Connection.h:111
NeuronID * get_row_begin(NeuronID i)
Definition: ComplexMatrix.h:940
bool evolve_locally()
Returns true if the calling instance has units which are integrated on the current rank...
Definition: SpikingGroup.cpp:323
T * get_data_begin(const StateID z=0)
Returns pointer to data value corresponding to the first element.
Definition: ComplexMatrix.h:971
float AurynFloat
Low precision floating point datatype.
Definition: auryn_definitions.h:157
AurynFloat get_spike_attribute(const NeuronID i, const int attribute_id=0)
Returns spike attribute belonging to the spike at position i in the get_spikes() SpikeContainer.
Definition: Connection.cpp:242
unsigned int NeuronID
NeuronID is an unsigned integeger type used to index neurons in Auryn.
Definition: auryn_definitions.h:151
Here is the call graph for this function:

◆ push_attributes()

void STPConnection::push_attributes ( )

Internal function to push spike attributes.

103 {
104  // need to push one attribute for each spike
106  for (SpikeContainer::const_iterator spike = spikes->begin() ;
107  spike != spikes->end() ; ++spike ) {
108  // dynamics
109  NeuronID spk = src->global2rank(*spike);
110  double x = auryn_vector_float_get( state_x, spk );
111  double u = auryn_vector_float_get( state_u, spk );
112  auryn_vector_float_set( state_x, spk, x-u*x );
113  auryn_vector_float_set( state_u, spk, u+Ujump*(1-u) );
114 
115  // TODO spike translation or introduce local_spikes
116  // function in SpikingGroup and implement this there ... (better option)
117  src->push_attribute( x*u );
118 
119  }
120 
121  // If we had two spike attributes in this connection we push
122  // the second attribute for each spike here:
123  //
124  // SpikeContainer * spikes = src->get_spikes_immediate();
125  // for (SpikeContainer::const_iterator spike = spikes->begin() ;
126  // spike != spikes->end() ; ++spike ) {
127  // AurynFloat other_attribute = foo+bar;
128  // src->push_attribute( other_attribute );
129  // }
130 }
NeuronID global2rank(NeuronID i)
Converts global NeuronID within the SpikingGroup to the local NeuronID on this rank.
Definition: SpikingGroup.h:446
std::vector< NeuronID > SpikeContainer
Spike container type. Used for storing spikes.
Definition: auryn_definitions.h:161
double Ujump
Definition: STPConnection.h:62
SpikingGroup * src
Pointer to the source group of this connection.
Definition: Connection.h:108
AurynFloat auryn_vector_float_get(auryn_vector_float *v, const NeuronID i)
Definition: auryn_definitions.cpp:123
SpikeContainer * get_spikes_immediate()
Returns pointer to SpikeContainer of spikes generated during the last evolve() step.
Definition: SpikingGroup.cpp:250
void push_attribute(AurynFloat attrib)
Pushes a spike attribute into the axonal SpikeDelay buffer.
Definition: SpikingGroup.cpp:275
unsigned int NeuronID
NeuronID is an unsigned integeger type used to index neurons in Auryn.
Definition: auryn_definitions.h:151
void auryn_vector_float_set(auryn_vector_float *v, const NeuronID i, AurynFloat x)
Definition: auryn_definitions.cpp:131
Here is the call graph for this function:

◆ set_tau_d()

void STPConnection::set_tau_d ( AurynFloat  taud)

Setter for tau_d, the timescale of synaptic depression.

180  {
181  tau_d = taud;
182 }
double tau_d
Definition: STPConnection.h:60

◆ set_tau_f()

void STPConnection::set_tau_f ( AurynFloat  tauf)

Setter for tau_f, the timescale of synaptic facilitation.

176  {
177  tau_f = tauf;
178 }
double tau_f
Definition: STPConnection.h:61

◆ set_ujump()

void STPConnection::set_ujump ( AurynFloat  r)

Setter for U_jump, which specifies the spike triggered change in the U equation in the model. Typically the same as urest.

184  {
185  Ujump = r;
186 }
r
Definition: mkpat.py:9
double Ujump
Definition: STPConnection.h:62

Member Data Documentation

◆ tau_d

double auryn::STPConnection::tau_d

◆ tau_f

double auryn::STPConnection::tau_f

◆ Ujump

double auryn::STPConnection::Ujump

The documentation for this class was generated from the following files: