Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 11f84f460e
Fetching contributors…

Cannot retrieve contributors at this time

196 lines (167 sloc) 2.374 kb
#include dummy.cfg;
#include izhikevich.cfg.d;
mechanism AEIF
{
state V = -65;
immutable V_tol = 0.05;
state u = -5;
immutable u_tol = 0.02;
local I;
threshold spike
{
state = V;
condition = "> 0";
code =
"
V = -70.6;
u += 0.0805;
delay = 5;
";
event_source = true;
reset_dt = true;
}
stage0 =
"
I = 0;
";
stage2 =
"
V' = (30 * (-(V + 70.6) + 2 * exp((V + 50.4) / 2)) - u + I) / 281;
u' = (4 * (V + 70.6) - u) / 144;
";
}
mechanism IzhMech2
{
state V = -65;
immutable V_tol = 0.2;
state u = -5;
immutable u_tol = 0.02;
local I;
threshold spike
{
state = V;
condition = "> 0";
code =
"
V = -65;
u += 2;
delay = 5;
";
event_source = true;
reset_dt = true;
}
stage0 =
"
I = 0;
";
stage2 =
"
V' = (0.04f * V + 5) * V + 140 - u + I;
u' = 0.01f * (0.2f * V - u);
";
}
mechanism IClamp
{
stage1 =
"
if(i % 2 == 0)
I += amp + 3;
else
I += amp;
";
external I;
constant amp;
}
mechanism RandSyn
{
pre_step =
"
if(rand() > 0.7)
{
r += 0.02;
reset_dt();
}
";
stage1 = "I += r * (0 - V);";
stage2 = "r' = -r / 2.0;";
external I;
external V;
state r;
immutable r_tol = 0.01;
}
synapse ExpSyn
{
stage1 = "I += s * (E - V);";
stage2 = "s' = -s / tau;";
syn_code = "s += gsyn * weight;";
constant gsyn = 0.1;
constant tau = 5;
constant E = 0;
external V;
state s;
immutable s_tol = 0.01;
syn_global weight
{
init = 1;
read_only = true;
}
syn_global counter = 0;
syn_threshold spike
{
state = V;
condition = "> 0";
code =
"
counter += 1;
";
}
}
neuron Regular
{
record_length = 10000;
record_rate = 100;
circ_buffer_size = 10;
num_src_synapses = 150;
rand_state_len = 2;
min_dt = 0.1;
pre_stage =
"
record(1, V); //flags, val
";
mechanism Izhikevich;
//mechanism AEIF;
mechanism IClamp
{
amp = 3.5; // For Izh, connected
//amp = 6.5; // For Izh, unconnected
//amp = 650.5; //for AEIF
}
mechanism RandSyn;
synapse ExpSyn
{
prefix = glu;
number = 150;
gsyn = 0.004;
immutable E = 0;
immutable tau;
}
/*synapse ExpSyn
{
prefix = gaba;
number = 10;
E = -80;
gsyn = 0.5;
}
}*/
connector RandConn;
}
connector RandConn
{
code =
"
int dest = dest_start + cycle % (dest_end - dest_start);
if(dest != i && rand() < P)
connect(i, dest);
";
constant P = 1;
}
Jump to Line
Something went wrong with that request. Please try again.