Common functions for matrix generation.
More...
Go to the source code of this file.
|
static struct delay_value | get_delay (uint16_t delay_value, uint32_t max_stage, uint32_t max_delay_per_stage) |
| Get a converted delay value and stage.
|
|
static void * | get_row (uint32_t *synaptic_matrix, uint32_t max_row_n_words, uint32_t pre_index) |
| Get a synaptic row for a given neuron.
|
|
static void * | get_delay_row (uint32_t *delayed_synaptic_matrix, uint32_t max_delayed_row_n_words, uint32_t pre_index, uint32_t delay_stage, uint32_t n_pre_neurons_per_core, uint32_t max_delay_stage, uint32_t n_pre_neurons) |
| Get a delayed synaptic row for a given neuron and delay stage.
|
|
Common functions for matrix generation.
Definition in file matrix_generator_common.h.
◆ delay_value
A converted final delay value and delay stage.
Definition at line 35 of file matrix_generator_common.h.
Data Fields |
uint16_t |
delay |
|
uint16_t |
stage |
|
◆ N_HEADER_WORDS
◆ get_delay()
static struct delay_value get_delay |
( |
uint16_t |
delay_value, |
|
|
uint32_t |
max_stage, |
|
|
uint32_t |
max_delay_per_stage |
|
) |
| |
|
static |
Get a converted delay value and stage.
- Parameters
-
[in] | delay_value | The value to convert |
[in] | max_stage | The maximum delay stage allowed |
[in] | max_delay_per_stage | The max delay in a delay stage |
- Returns
- The converted delay value
Definition at line 47 of file matrix_generator_common.h.
◆ get_row()
static void * get_row |
( |
uint32_t * |
synaptic_matrix, |
|
|
uint32_t |
max_row_n_words, |
|
|
uint32_t |
pre_index |
|
) |
| |
|
static |
Get a synaptic row for a given neuron.
- Parameters
-
[in] | synaptic_matrix | the address of the synaptic matrix |
[in] | max_row_n_words | the maximum number of words (excluding headers) in each row of the table |
[in] | pre_index | the index of the pre-neuron relative to the start of the matrix |
- Returns
- A pointer to the row of the matrix to write to
Definition at line 80 of file matrix_generator_common.h.
◆ get_delay_row()
static void * get_delay_row |
( |
uint32_t * |
delayed_synaptic_matrix, |
|
|
uint32_t |
max_delayed_row_n_words, |
|
|
uint32_t |
pre_index, |
|
|
uint32_t |
delay_stage, |
|
|
uint32_t |
n_pre_neurons_per_core, |
|
|
uint32_t |
max_delay_stage, |
|
|
uint32_t |
n_pre_neurons |
|
) |
| |
|
static |
Get a delayed synaptic row for a given neuron and delay stage.
- Parameters
-
[in] | delayed | synaptic_matrix the address of the delayed synaptic matrix |
[in] | max_delayed_row_n_words | the maximum number of words (excluding headers) in each delayed row of the table |
[in] | pre_index | the index of the pre-neuron relative to the start of the matrix |
[in] | delay_stage | the delay stage, where 0 means the undelayed stage |
[in] | n_pre_neurons_per_core | The number of neurons per core in the pre-population |
[in] | max_delay_stage | The maximum delay stage |
[in] | n_pre_neurons | The number of neurons in the pre-population |
- Returns
- A pointer to the row of the delayed matrix to write to
Definition at line 99 of file matrix_generator_common.h.