sPyNNaker neural_modelling 7.1.1
Loading...
Searching...
No Matches
Data Structures | Macros | Functions | Variables
synapse_expander.c File Reference

The synapse expander for neuron cores. More...

#include "matrix_generator.h"
#include "connection_generator.h"
#include "param_generator.h"
#include "rng.h"
#include <spin1_api.h>
#include <data_specification.h>
#include <debug.h>
#include <key_atom_map.h>
#include "common_mem.h"
#include "bit_field_expander.h"

Go to the source code of this file.

Data Structures

struct  connection_builder_config_t
 The configuration of the connection builder. More...
 

Macros

#define INVALID_REGION_ID   0xFFFFFFFF
 

Functions

static bool read_connection_builder_region (void **region, void *synaptic_matrix, uint32_t post_slice_start, uint32_t post_slice_count, uint32_t post_index, unsigned long accum *weight_scales, accum timestep_per_delay)
 Generate the synapses for a single connector. More...
 
static bool run_synapse_expander (data_specification_metadata_t *ds_regions, void *params_address)
 Read the data for the expander. More...
 
void c_main (void)
 Entry point. More...
 

Variables

 expander_config_t
 
rng_tpopulation_rng
 An RNG that starts in the same place on every core of the Population. More...
 
rng_tcore_rng
 An RNG that is local to the current core. More...
 

Detailed Description

The synapse expander for neuron cores.

Definition in file synapse_expander.c.


Data Structure Documentation

◆ connection_builder_config_t

struct connection_builder_config_t

The configuration of the connection builder.

Definition at line 38 of file synapse_expander.c.

Data Fields
uint32_t pre_lo
uint32_t pre_hi
uint32_t post_lo
uint32_t post_hi
uint32_t synapse_type
uint32_t matrix_type
uint32_t connector_type
uint32_t weight_type
uint32_t delay_type

Macro Definition Documentation

◆ INVALID_REGION_ID

#define INVALID_REGION_ID   0xFFFFFFFF

Definition at line 35 of file synapse_expander.c.

Function Documentation

◆ read_connection_builder_region()

static bool read_connection_builder_region ( void **  region,
void *  synaptic_matrix,
uint32_t  post_slice_start,
uint32_t  post_slice_count,
uint32_t  post_index,
unsigned long accum *  weight_scales,
accum  timestep_per_delay 
)
static

Generate the synapses for a single connector.

Parameters
[in,out]in_regionThe address to read the parameters from. Should be updated to the position just after the parameters after calling.
[in]synaptic_matrix_regionThe address of the synaptic matrices
[in]post_slice_startThe start of the slice of the post-population to generate for
[in]post_slice_countThe number of neurons to generate for
[in]n_synapse_type_bitsThe number of bits in the synapse type
[in]n_synapse_index_bitsThe number of bits for the neuron index id
[in]weight_scalesAn array of weight scales, one for each synapse type
Returns
true on success, false on failure

Definition at line 88 of file synapse_expander.c.

◆ run_synapse_expander()

static bool run_synapse_expander ( data_specification_metadata_t ds_regions,
void *  params_address 
)
static

Read the data for the expander.

Parameters
[in]ds_regionsThe data specification regions
[in]params_addressThe address of the expander parameters
Returns
True if the expander finished correctly, False if there was an error

Definition at line 137 of file synapse_expander.c.

◆ c_main()

void c_main ( void  )

Entry point.

Definition at line 203 of file synapse_expander.c.

Variable Documentation

◆ expander_config_t

expander_config_t

Definition at line 68 of file synapse_expander.c.

◆ population_rng

rng_t* population_rng

An RNG that starts in the same place on every core of the Population.

Definition at line 70 of file synapse_expander.c.

◆ core_rng

rng_t* core_rng

An RNG that is local to the current core.

Definition at line 71 of file synapse_expander.c.