Last modified by adavison on 2022/10/04 13:55

From version 11.2
edited by adavison
on 2021/09/30 13:51
Change comment: There is no comment for this version
To version 11.3
edited by adavison
on 2021/09/30 14:01
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -197,8 +197,44 @@
197 197  
198 198  Now if we run our simulation again, we can see the effect of this heterogeneity in the neuron population.
199 199  
200 -TO BE COMPLETED
200 +(% class="box successmessage" %)
201 +(((
202 +**Slide** showing addition of second population, and of connections between them
203 +)))
201 201  
205 +(% class="wikigeneratedid" %)
206 +So far we have a population of neurons, but there are no connections between them, we don't have a network. Let's add a second population of the same size as the first, but we'll set the offset current to zero, so they don't fire action potentials spontaneously.
207 +
208 +(% class="box infomessage" %)
209 +(((
210 +**Screencast** - current state of editor
211 +\\(% style="color:#000000" %)"""Simple network model using PyNN"""
212 +\\import pyNN.nest as sim(%%)
213 +(% style="color:#000000" %)from pyNN.utility.plotting import Figure, Panel(%%)
214 +(% style="color:#000000" %)from pyNN.random import RandomDistribution(%%)
215 +(% style="color:#000000" %)sim.setup(timestep=0.1)(%%)
216 +(% style="color:#000000" %)cell_type  = sim.IF_curr_exp(
217 + (% style="color:#e74c3c" %) (% style="color:#000000" %)v_rest=RandomDistribution('normal', {'mu': -65.0, 'sigma': 1.0}),
218 + v_thresh=RandomDistribution('normal', {'mu': -55.0, 'sigma': 1.0}),
219 + v_reset=RandomDistribution('normal', {'mu': -65.0, 'sigma': 1.0}), (%%)
220 +(% style="color:#000000" %) t_refrac=1, tau_m=10, cm=1, i_offset=0.1)(%%)
221 +(% style="color:#000000" %)population1 = sim.Population(100, cell_type, label="Population 1")(%%)
222 +(% style="color:#000000" %)population1.record("v")
223 +sim.run(100.0)(%%)
224 +(% style="color:#000000" %)data_v = population1.get_data().segments[0].filter(name='v')[0]
225 +Figure(
226 + Panel(
227 + data_v[:, 0:5],
228 + xticks=True, xlabel="Time (ms)",
229 + yticks=True, ylabel="Membrane potential (mV)"
230 + ),
231 + title="Response of first five neurons with heterogeneous parameters",
232 + annotations="Simulated with NEST"
233 +).show()(%%)
234 +\\**Run script in terminal, show figure**
235 +)))
236 +
237 +
202 202  (% class="wikigeneratedid" id="HSummary28Inthistutorial2CyouhavelearnedtodoX202629" %)
203 203  (% class="small" %)**Summary (In this tutorial, you have learned to do X…)**
204 204