Skip to content

Updating Extra Global Parameters at runtime #606

Discussion options

You must be logged in to vote

So what you need to do is:

  1. When you first initialize the extra global parameter with P.set_extra_global_param("spikeTimes", flat_neuron_spike_times), you need to make it large enough for your largest spike array (I tend to use np.empty(max_size) for this.
  2. Every 200ms, update the extra global parameters through its 'view' at P.extra_global_params["spikeTimes"].view[:len(spikes)] = spikes
  3. Call P.push_extra_global_param_to_device("spikeTimes") are you are already doing

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@why9928
Comment options

Answer selected by why9928
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants