Dear nest community,

I have a network of 'iaf_cond_alpha' neurons and want to use the 'dc_generator' to apply two different current amplitudes to the network. (see code below)
I created a random number of indices of neurons that should receive a suprathreshold current, the rest of the neurons should receive the subthreshold current.

However, there doesn't seem any way to set the current amplitude to a subset of neurons. I have looked at all the examples using the dc_generator but couldn't find anything about it. 

How can this be done? Is it possible? If it's not possible could you point me to the source code so I could potentially write a something for it?

Thank you.

Kind regards,
Daphne 


=== code ===

np.random.seed(0) # for reproducibility

# amplitudes
Asub = 300.6
Asupra = 367.4

# list of all neurons
neuron_idx_lst = np.arange(0,N_total) 

# create random array, these are the neurons that should be stimulated with supra Amplitude
supra_indices = np.random.randint(1, N_total, size=int(N_total/neuron_groups-1))

# the rest should receive sub threshold current
sub_indices = np.setdiff1d(neuron_idx_lst,supra_indices)

# here is where it goes wrong
nest.SetStatus(dc_gen[supra_indices], params={'amplitude':Asupra, 'start':stim_start, 'stop':stim_end})

nest.SetStatus(dc_gen[sub_indices], params={'amplitude':Asub, 'start':stim_start, 'stop':stim_end})

>>> TypeError: tuple indices must be integers or slices, not tuple