sPyNNaker neural_modelling  development
timing_recurrent_pre_stochastic_impl.c
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2017 The University of Manchester
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * https://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
20 
21 //---------------------------------------
22 // Globals
23 //---------------------------------------
24 // Exponential lookup-tables
31 
34 
36 typedef struct {
37  int32_t accumulator_depression_plus_one;
38  int32_t accumulator_potentiation_minus_one;
41  uint32_t following_data[];
43 
44 //---------------------------------------
45 // Functions
46 //---------------------------------------
47 address_t timing_initialise(address_t address) {
49 
50  // Copy plasticity region data from address
51  // **NOTE** this seems somewhat safer than relying on sizeof
53  config->accumulator_depression_plus_one;
55  config->accumulator_potentiation_minus_one;
56 
57  log_debug("\tAccumulator depression=%d, Accumulator potentiation=%d",
60 
61  // Copy LUTs from following memory
62  spin1_memcpy(pre_exp_dist_lookup, config->pre_exp_dist_lookup,
63  sizeof(config->pre_exp_dist_lookup));
64  spin1_memcpy(post_exp_dist_lookup, config->post_exp_dist_lookup,
65  sizeof(config->post_exp_dist_lookup));
66 
67  return config->following_data;
68 }
static struct local_only_config config
A local copy of the configuration.
Definition: local_only.c:43
#define STDP_FIXED_POINT_ONE
The number 1.0 in the fixed point math used by STDP.
Definition: stdp_typedefs.h:31
uint16_t pre_exp_dist_lookup[STDP_FIXED_POINT_ONE]
Lookup table for picking exponentially distributed random value for pre-traces.
plasticity_trace_region_data_t plasticity_trace_region_data
Global plasticity parameter data.
uint16_t post_exp_dist_lookup[STDP_FIXED_POINT_ONE]
Lookup table for picking exponentially distributed random value for pre-traces.
address_t timing_initialise(address_t address)
Initialise the timing dependence state (global) from SDRAM.
How the configuration data for pre_stochastic is laid out in SDRAM.
Recurrent stochastic timing rule.
int32_t accumulator_potentiation_minus_one
Threshold below which we won't hit potentiation trigger after increment.
int32_t accumulator_depression_plus_one
Threshold above which we won't hit depression trigger after decrement.
Configuration information about plasticity traces.