brainpy.math.syn2post#
- brainpy.math.syn2post(syn_values, post_ids, post_num, indices_are_sorted=False)#
The syn-to-post summation computation.
This function is equivalent to:
post_val = np.zeros(post_num) for syn_i, post_i in enumerate(post_ids): post_val[post_i] += syn_values[syn_i]
- Parameters:
syn_values (ArrayType) – The synaptic values.
post_ids (ArrayType) – The post-synaptic neuron ids.
post_num (int) – The number of the post-synaptic neurons.
- Returns:
post_val – The post-synaptic value.
- Return type:
ArrayType