Skip to content

Commit f235807

Browse files
author
Daniel Incicau
committed
Document parameters in both .py and .ipynb
1 parent f00bc57 commit f235807

File tree

6 files changed

+93
-94
lines changed

6 files changed

+93
-94
lines changed

notebooks/layer5_CC_CS_connection.ipynb

Lines changed: 23 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
"metadata": {},
2525
"outputs": [],
2626
"source": [
27-
"PLOT_ONLY_FROM_EQUILIBRIUM=True\n",
28-
"BIN_SIZE_FIRING_RATE = 10\n",
27+
"PLOT_ONLY_FROM_EQUILIBRIUM=True # Plot graphs only from equilibrium time\n",
28+
"BIN_SIZE_FIRING_RATE = 10 # Number of bins for firing rates historgram\n",
2929
"USE_SYNAPSE_PROBS = True\n",
3030
"USE_DENDRITE_MODEL = False\n",
3131
"\n",
@@ -37,8 +37,8 @@
3737
" 3: 'PV'\n",
3838
"}\n",
3939
"\n",
40-
"equilibrium_t = 0.2*second\n",
41-
"no_simulations = 20"
40+
"equilibrium_t = 0.2*second # Default equilibirium time. Should be set based on previous simulation results\n",
41+
"no_simulations = 20 # Number of simulations to be conducted & their results are averaged"
4242
]
4343
},
4444
{
@@ -51,28 +51,29 @@
5151
"################################################################################\n",
5252
"# Model parameters\n",
5353
"################################################################################\n",
54+
"\n",
5455
"### General parameters\n",
5556
"duration = 3*second # Total simulation time\n",
56-
"sim_dt = 0.1*ms # Integrator/sampling step\n",
57+
"sim_dt = 0.1*ms # Integrator/sampling step\n",
5758
"\n",
5859
"N_sst = 34 # Number of SST neurons (inhibitory)\n",
5960
"N_pv = 46 # Number of PV neurons (inhibitory)\n",
60-
"N_cc = 275 # Number of CC neurons (excitatory)\n",
61-
"N_cs = 45 # Number of CS neurons (excitatory)\n",
61+
"N_cc = 275 # Number of CC (PYR) neurons (excitatory)\n",
62+
"N_cs = 45 # Number of CS (PYR) neurons (excitatory)\n",
6263
"N = [N_cs, N_cc, N_sst, N_pv]\n",
6364
"\n",
6465
"### Neuron parameters\n",
65-
"tau_S = 16*ms # \n",
66-
"tau_D = 7*ms #\n",
67-
"tau_SST = 20*ms #\n",
68-
"tau_PV = 10*ms #\n",
66+
"tau_S = 16*ms # PYR neuron - soma membrane time constant \n",
67+
"tau_D = 7*ms # PYR neuron - dendritic membrane time constant\n",
68+
"tau_SST = 20*ms # SST neuron membrane time constant\n",
69+
"tau_PV = 10*ms # PV neuron membrane time constant\n",
6970
"tau_E = 5*ms # Excitatory synaptic time constant\n",
7071
"tau_I = 10*ms # Inhibitory synaptic time constant\n",
7172
"\n",
72-
"C_S = 370*pF\n",
73-
"C_D = 170*pF\n",
74-
"C_SST = 100*pF\n",
75-
"C_PV = 100*pF\n",
73+
"C_S = 370*pF # PYR neuron - soma membrane capacitance\n",
74+
"C_D = 170*pF # PYR neuron - dendritic membrane capacitance\n",
75+
"C_SST = 100*pF # SST neuron membrane capacitance\n",
76+
"C_PV = 100*pF # PV neuron membrane capacitance\n",
7677
"\n",
7778
"E_l = -70*mV # leak reversal potential\n",
7879
"E_e = 0*mV # Excitatory synaptic reversal potential\n",
@@ -88,26 +89,21 @@
8889
"### Connectivity weight & probabilities\n",
8990
"# CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9091
"conn_weights = [0.27, 0.05, 1.01, 0.19, 0.32, 0.24, 0.09, 0.48, 0.19, 0.52, 0.19, 0.18, 0.19, 0.47, 0.44] # in nS\n",
91-
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9292
"if USE_SYNAPSE_PROBS: \n",
9393
" # CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9494
" conn_probs = [0.16, 0.23, 0.18, 0.52, 0.43, 0.06, 0.26, 0.22, 0.13, 0.38, 0.09, 0.29, 0.1, 0.5, 0.14]\n",
95+
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9596
"else: \n",
9697
" conn_probs = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]\n",
9798
"\n",
98-
"### External Input\n",
99+
"### External input amplitude & steady state\n",
99100
"I_sst_amp = 50\n",
100101
"I_pv_amp = 50\n",
101102
"I_cc_amp = 200\n",
102103
"I_cs_amp = 100\n",
103104
"\n",
104-
"I_sst_steady = 0\n",
105-
"I_pv_steady = 0\n",
106-
"I_cc_steady = 0\n",
107-
"I_cs_steady = 0\n",
108-
"\n",
109-
"\n",
110-
"lambda_cs = lambda_cc = lambda_sst = lambda_pv = 10*Hz\n",
105+
"I_sst_steady = I_pv_steady = I_cc_steady = I_cs_steady = 0\n",
106+
"ambda_sst = lambda_pv = lambda_cc = lambda_cs = 10*Hz\n",
111107
"\n",
112108
"input_steady = [I_cs_steady, I_cc_steady, I_sst_steady, I_pv_steady]\n",
113109
"input_amplitudes = [I_cs_amp, I_cc_amp, I_sst_amp, I_pv_amp]\n",
@@ -121,7 +117,10 @@
121117
"spatial_phase = 1\n",
122118
"tsteps = int(duration / sim_dt)\n",
123119
"\n",
120+
"### Simulation weights for CC->CS connection probabilities\n",
124121
"cc_cs_weights = [0, 0.125, 0.25, 0.5, 1, 2, 4, 8]\n",
122+
"\n",
123+
"### Degrees for simulated orientation input\n",
125124
"degrees = [0, 90, 180, 270]\n",
126125
"\n",
127126
"################################################################################"

notebooks/layer5_SST_Soma_selectivity.ipynb

Lines changed: 24 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
"metadata": {},
2525
"outputs": [],
2626
"source": [
27-
"PLOT_ONLY_FROM_EQUILIBRIUM=True\n",
28-
"BIN_SIZE_FIRING_RATE = 10\n",
27+
"PLOT_ONLY_FROM_EQUILIBRIUM=True # Plot graphs only from equilibrium time\n",
28+
"BIN_SIZE_FIRING_RATE = 10 # Number of bins for firing rates historgram\n",
2929
"USE_SYNAPSE_PROBS = True\n",
3030
"\n",
3131
"### This simulation always uses the dendrite model due to applying different weight schemes SST->Soma/Dendrite\n",
@@ -39,8 +39,8 @@
3939
" 3: 'PV'\n",
4040
"}\n",
4141
"\n",
42-
"equilibrium_t = 0.2*second\n",
43-
"no_simulations = 20"
42+
"equilibrium_t = 0.2*second # Default equilibirium time. Should be set based on previous simulation results\n",
43+
"no_simulations = 20 # Number of simulations to be conducted & their results are averaged"
4444
]
4545
},
4646
{
@@ -55,26 +55,26 @@
5555
"################################################################################\n",
5656
"### General parameters\n",
5757
"duration = 3*second # Total simulation time\n",
58-
"sim_dt = 0.1*ms # Integrator/sampling step\n",
58+
"sim_dt = 0.1*ms # Integrator/sampling step\n",
5959
"\n",
60-
"N_sst = 34 # Number of SST neurons (inhibitory)\n",
61-
"N_pv = 46 # Number of PV neurons (inhibitory)\n",
62-
"N_cc = 275 # Number of CC neurons (excitatory)\n",
63-
"N_cs = 45 # Number of CS neurons (excitatory)\n",
60+
"N_sst = 34 # Number of SST neurons (inhibitory)\n",
61+
"N_pv = 46 # Number of PV neurons (inhibitory)\n",
62+
"N_cc = 275 # Number of CC (PYR) neurons (excitatory)\n",
63+
"N_cs = 45 # Number of CS (PYR) neurons (excitatory)\n",
6464
"N = [N_cs, N_cc, N_sst, N_pv]\n",
6565
"\n",
6666
"### Neuron parameters\n",
67-
"tau_S = 16*ms # \n",
68-
"tau_D = 7*ms #\n",
69-
"tau_SST = 20*ms #\n",
70-
"tau_PV = 10*ms #\n",
67+
"tau_S = 16*ms # PYR neuron - soma membrane time constant\n",
68+
"tau_D = 7*ms # PYR neuron - dendritic membrane time constant\n",
69+
"tau_SST = 20*ms # SST neuron membrane time constant\n",
70+
"tau_PV = 10*ms # PV neuron membrane time constant\n",
7171
"tau_E = 5*ms # Excitatory synaptic time constant\n",
7272
"tau_I = 10*ms # Inhibitory synaptic time constant\n",
7373
"\n",
74-
"C_S = 370*pF\n",
75-
"C_D = 170*pF\n",
76-
"C_SST = 100*pF\n",
77-
"C_PV = 100*pF\n",
74+
"C_S = 370*pF # PYR neuron - soma membrane capacitance\n",
75+
"C_D = 170*pF # PYR neuron - dendritic membrane capacitance\n",
76+
"C_SST = 100*pF # SST neuron membrane capacitance\n",
77+
"C_PV = 100*pF # PV neuron membrane capacitance\n",
7878
"\n",
7979
"E_l = -70*mV # leak reversal potential\n",
8080
"E_e = 0*mV # Excitatory synaptic reversal potential\n",
@@ -90,26 +90,21 @@
9090
"### Connectivity weight & probabilities\n",
9191
"# CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9292
"conn_weights = [0.27, 0.05, 1.01, 0.19, 0.32, 0.24, 0.09, 0.48, 0.19, 0.52, 0.19, 0.18, 0.19, 0.47, 0.44] # in nS\n",
93-
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9493
"if USE_SYNAPSE_PROBS: \n",
9594
" # CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9695
" conn_probs = [0.16, 0.23, 0.18, 0.52, 0.43, 0.06, 0.26, 0.22, 0.13, 0.38, 0.09, 0.29, 0.1, 0.5, 0.14]\n",
96+
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9797
"else: \n",
9898
" conn_probs = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]\n",
9999
"\n",
100-
"### External Input\n",
100+
"### External input amplitude & steady state\n",
101101
"I_sst_amp = 50\n",
102102
"I_pv_amp = 50\n",
103103
"I_cc_amp = 200\n",
104104
"I_cs_amp = 100\n",
105105
"\n",
106-
"I_sst_steady = 0\n",
107-
"I_pv_steady = 0\n",
108-
"I_cc_steady = 0\n",
109-
"I_cs_steady = 0\n",
110-
"\n",
111-
"\n",
112-
"lambda_cs = lambda_cc = lambda_sst = lambda_pv = 10*Hz\n",
106+
"I_sst_steady = I_pv_steady = I_cc_steady = I_cs_steady = 0\n",
107+
"lambda_sst = lambda_pv = lambda_cc = lambda_cs = 10*Hz\n",
113108
"\n",
114109
"input_steady = [I_cs_steady, I_cc_steady, I_sst_steady, I_pv_steady]\n",
115110
"input_amplitudes = [I_cs_amp, I_cc_amp, I_sst_amp, I_pv_amp]\n",
@@ -123,7 +118,10 @@
123118
"spatial_phase = 1\n",
124119
"tsteps = int(duration / sim_dt)\n",
125120
"\n",
121+
"### Simulation weights for SST->CC Soma & SST->CS Soma connection probabilities\n",
126122
"sst_soma_conn_weights = [0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1]\n",
123+
"\n",
124+
"### Degrees for simulated orientation input\n",
127125
"degrees = [0, 90, 180, 270]\n",
128126
"\n",
129127
"################################################################################"

notebooks/layer5_sandbox.ipynb

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -60,22 +60,22 @@
6060
"# N_cc = N_cs = 400 # Number of CC neurons & CS neurons each (excitatory)\n",
6161
"N_sst = 10 # Number of SST neurons (inhibitory)\n",
6262
"N_pv = 10 # Number of PV neurons (inhibitory)\n",
63-
"N_cc = 40 # Number of CC neurons (excitatory)\n",
64-
"N_cs = 40 # Number of CS neurons (excitatory)\n",
63+
"N_cc = 40 # Number of CC (PYR) neurons (excitatory)\n",
64+
"N_cs = 40 # Number of CS (PYR) neurons (excitatory)\n",
6565
"\n",
6666
"### Neuron parameters\n",
67-
"tau_S = 16*ms # \n",
68-
"tau_D = 7*ms #\n",
69-
"tau_SST = 20*ms #\n",
70-
"tau_PV = 10*ms #\n",
67+
"tau_S = 16*ms # PYR neuron - soma membrane time constant \n",
68+
"tau_D = 7*ms # PYR neuron - dendritic membrane time constant\n",
69+
"tau_SST = 20*ms # SST neuron membrane time constant\n",
70+
"tau_PV = 10*ms # PV neuron membrane time constant\n",
7171
"tau_E = 5*ms # Excitatory synaptic time constant\n",
7272
"tau_I = 10*ms # Inhibitory synaptic time constant\n",
7373
"\n",
74-
"C_S = 370*pF\n",
75-
"C_D = 170*pF\n",
76-
"C_SST = 100*pF\n",
77-
"C_PV = 100*pF\n",
78-
"\n",
74+
"C_S = 370*pF # PYR neuron - soma membrane capacitance\n",
75+
"C_D = 170*pF # PYR neuron - dendritic membrane capacitance\n",
76+
"C_SST = 100*pF # SST neuron membrane capacitance\n",
77+
"C_PV = 100*pF # PV neuron membrane capacitance\n",
78+
" \n",
7979
"E_l = -70*mV # leak reversal potential\n",
8080
"E_e = 0*mV # Excitatory synaptic reversal potential\n",
8181
"E_i = -80*mV # Inhibitory synaptic reversal potential\n",
@@ -90,10 +90,10 @@
9090
"### Connectivity weight & probabilities\n",
9191
"# CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9292
"conn_weights = [0.27, 0.05, 1.01, 0.19, 0.32, 0.24, 0.09, 0.48, 0.19, 0.52, 0.19, 0.18, 0.19, 0.47, 0.44] # in nS\n",
93-
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9493
"if USE_SYNAPSE_PROBS: \n",
9594
" # CS_CS 0, CS_SST 1, CS_PV 2, SST_CS 3, PV_CS 4, CC_CC 5, CC_SST 6, CC_PV 7, SST_CC 8, PV_CC 9, CC_CS 10, SST_PV 11, SST_SST 12, PV_PV 13, PV_SST 14, \n",
9695
" conn_probs = [0.16, 0.23, 0.18, 0.52, 0.43, 0.06, 0.26, 0.22, 0.13, 0.38, 0.09, 0.29, 0.1, 0.5, 0.14]\n",
96+
"# If not `USE_SYNAPSE_PROBS`, the topology is maintained as specified with a probability p=1\n",
9797
"else: \n",
9898
" conn_probs = [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]\n",
9999
"\n",

notebooks/test_different_inputs.ipynb

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,27 +29,28 @@
2929
"################################################################################\n",
3030
"# Model parameters\n",
3131
"################################################################################\n",
32+
"\n",
3233
"### General parameters\n",
3334
"duration = 10*second # Total simulation time\n",
34-
"sim_dt = 0.1*ms # Integrator/sampling step\n",
35+
"sim_dt = 0.1*ms # Integrator/sampling step\n",
3536
"\n",
3637
"N_sst = 2 # Number of SST neurons (inhibitory)\n",
3738
"N_pv = 2 # Number of PV neurons (inhibitory)\n",
38-
"N_cc = 2 # Number of CC neurons (excitatory)\n",
39-
"N_cs = 2 # Number of CS neurons (excitatory)\n",
39+
"N_cc = 2 # Number of CC (PYR) neurons (excitatory)\n",
40+
"N_cs = 2 # Number of CS (PYR) neurons (excitatory)\n",
4041
"\n",
4142
"### Neuron parameters\n",
42-
"tau_S = 16*ms # \n",
43-
"tau_D = 7*ms #\n",
44-
"tau_SST = 20*ms #\n",
45-
"tau_PV = 10*ms #\n",
43+
"tau_S = 16*ms # PYR neuron - soma membrane time constant\n",
44+
"tau_D = 7*ms # PYR neuron - dendritic membrane time constant\n",
45+
"tau_SST = 20*ms # SST neuron membrane time constant\n",
46+
"tau_PV = 10*ms # PV neuron membrane time constant\n",
4647
"tau_E = 5*ms # Excitatory synaptic time constant\n",
4748
"tau_I = 10*ms # Inhibitory synaptic time constant\n",
4849
"\n",
49-
"C_S = 370*pF\n",
50-
"C_D = 170*pF\n",
51-
"C_SST = 100*pF\n",
52-
"C_PV = 100*pF\n",
50+
"C_S = 370*pF # PYR neuron - soma membrane capacitance\n",
51+
"C_D = 170*pF # PYR neuron - dendritic membrane capacitance\n",
52+
"C_SST = 100*pF # SST neuron membrane capacitance\n",
53+
"C_PV = 100*pF # PV neuron membrane capacitance\n",
5354
"\n",
5455
"E_l = -70*mV # leak reversal potential\n",
5556
"E_e = 0*mV # Excitatory synaptic reversal potential\n",

notebooks/test_single_neurons.ipynb

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -26,27 +26,28 @@
2626
"################################################################################\n",
2727
"# Model parameters\n",
2828
"################################################################################\n",
29+
"\n",
2930
"### General parameters\n",
3031
"duration = 2*second # Total simulation time\n",
31-
"sim_dt = 0.1*ms # Integrator/sampling step\n",
32+
"sim_dt = 0.1*ms # Integrator/sampling step\n",
3233
"\n",
3334
"N_sst = 2 # Number of SST neurons (inhibitory)\n",
3435
"N_pv = 2 # Number of PV neurons (inhibitory)\n",
35-
"N_cc = 2 # Number of CC neurons (excitatory)\n",
36-
"N_cs = 2 # Number of CS neurons (excitatory)\n",
36+
"N_cc = 2 # Number of CC (PYR) neurons (excitatory)\n",
37+
"N_cs = 2 # Number of CS (PYR) neurons (excitatory)\n",
3738
"\n",
3839
"### Neuron parameters\n",
39-
"tau_S = 16*ms # \n",
40-
"tau_D = 7*ms #\n",
41-
"tau_SST = 20*ms #\n",
42-
"tau_PV = 10*ms #\n",
40+
"tau_S = 16*ms # PYR neuron - soma membrane time constant\n",
41+
"tau_D = 7*ms # PYR neuron - dendritic membrane time constant\n",
42+
"tau_SST = 20*ms # SST neuron membrane time constant\n",
43+
"tau_PV = 10*ms # PV neuron membrane time constant\n",
4344
"tau_E = 5*ms # Excitatory synaptic time constant\n",
4445
"tau_I = 10*ms # Inhibitory synaptic time constant\n",
4546
"\n",
46-
"C_S = 370*pF\n",
47-
"C_D = 170*pF\n",
48-
"C_SST = 100*pF\n",
49-
"C_PV = 100*pF\n",
47+
"C_S = 370*pF # PYR neuron - soma membrane capacitance\n",
48+
"C_D = 170*pF # PYR neuron - dendritic membrane capacitance\n",
49+
"C_SST = 100*pF # SST neuron membrane capacitance\n",
50+
"C_PV = 100*pF # PV neuron membrane capacitance\n",
5051
"\n",
5152
"E_l = -70*mV # leak reversal potential\n",
5253
"E_e = 0*mV # Excitatory synaptic reversal potential\n",

parameters.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,21 +12,21 @@
1212

1313
"N_sst": N_SST, # Number of SST neurons (inhibitory)
1414
"N_pv": N_PV, # Number of PV neurons (inhibitory)
15-
"N_cc": N_CC, # Number of CC neurons (excitatory)
16-
"N_cs": N_CS, # Number of CS neurons (excitatory)
15+
"N_cc": N_CC, # Number of CC (PYR) neurons (excitatory)
16+
"N_cs": N_CS, # Number of CS (PYR) neurons (excitatory)
1717

1818
### Neuron parameters
19-
"tau_S": 16 * ms,
20-
"tau_D": 7 * ms,
21-
"tau_SST": 20 * ms,
22-
"tau_PV": 10 * ms,
19+
"tau_S": 16 * ms, # PYR neuron - soma membrane time constant
20+
"tau_D": 7 * ms, # PYR neuron - dendritic membrane time constant
21+
"tau_SST": 20 * ms, # SST neuron membrane time constant
22+
"tau_PV": 10 * ms, # PV neuron membrane time constant
2323
"tau_E": 5 * ms, # Excitatory synaptic time constant
2424
"tau_I": 10 * ms, # Inhibitory synaptic time constant
2525

26-
"C_S": 370 * pF,
27-
"C_D": 170 * pF,
28-
"C_SST": 100 * pF,
29-
"C_PV": 100 * pF,
26+
"C_S": 370 * pF, # PYR neuron - soma membrane capacitance
27+
"C_D": 170 * pF, # PYR neuron - dendritic membrane capacitance
28+
"C_SST": 100 * pF, # SST neuron membrane capacitance
29+
"C_PV": 100 * pF, # PV neuron membrane capacitance
3030

3131
"E_l": -70 * mV, # leak reversal potential
3232
"E_e": 0 * mV, # Excitatory synaptic reversal potential

0 commit comments

Comments
 (0)