Seal Phase4AE same-precision GPU numerical gate and audit limits
This commit is contained in:
+72
@@ -0,0 +1,72 @@
|
||||
{
|
||||
"c0": -0.00025935108198051754,
|
||||
"cg": 0.004937935295309027,
|
||||
"cv": 0.9950124791926823,
|
||||
"gd": 0.9801986733067553,
|
||||
"metadata": {
|
||||
"constant_values_are_double": true,
|
||||
"float32_execution_note": "Brian NumPy scalar/array promotion and operation order must be matched separately; double coefficients alone do not assert float64 intermediate array arithmetic.",
|
||||
"g_expression": "gd * old_g",
|
||||
"hex": {
|
||||
"c0": "-0x1.0ff306a505980p-12",
|
||||
"cg": "0x1.439cce9a65d5bp-8",
|
||||
"cv": "0x1.fd7246927d28bp-1",
|
||||
"gd": "0x1.f5dc99badec5bp-1",
|
||||
"reset": "-0x1.a9fbe76c8b43ap-5",
|
||||
"seed_volt": "-0x1.6872b020c49bap-5",
|
||||
"threshold": "-0x1.70a3d70a3d70ap-5"
|
||||
},
|
||||
"names": {
|
||||
"c0": "_lio_8",
|
||||
"cg": "_lio_9",
|
||||
"cv": "_lio_10",
|
||||
"gd": "_lio_2"
|
||||
},
|
||||
"provenance": {
|
||||
"c0": {
|
||||
"code_object": "default_neurons_stateupdater_codeobject_24",
|
||||
"name": "_lio_8",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
},
|
||||
"cg": {
|
||||
"code_object": "default_neurons_stateupdater_codeobject_24",
|
||||
"name": "_lio_9",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
},
|
||||
"cv": {
|
||||
"code_object": "default_neurons_stateupdater_codeobject_24",
|
||||
"name": "_lio_10",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
},
|
||||
"gd": {
|
||||
"code_object": "default_neurons_stateupdater_codeobject_24",
|
||||
"name": "_lio_2",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
},
|
||||
"reset": {
|
||||
"code_object": "default_neurons_spike_resetter_codeobject_24",
|
||||
"name": "v_rst",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
},
|
||||
"seed_volt": {
|
||||
"source": "common request interface: unchanged v_th + 1 mV"
|
||||
},
|
||||
"threshold": {
|
||||
"code_object": "default_neurons_spike_thresholder_codeobject_24",
|
||||
"name": "v_th",
|
||||
"namespace_dtype": "float64",
|
||||
"source": "CodeObject.namespace"
|
||||
}
|
||||
},
|
||||
"units": "SI volts and dimensionless coefficients",
|
||||
"voltage_expression": "c0 + ((cg * old_g) + (cv * old_v))"
|
||||
},
|
||||
"reset": -0.052000000000000005,
|
||||
"seed_volt": -0.044,
|
||||
"threshold": -0.045
|
||||
}
|
||||
+154
@@ -0,0 +1,154 @@
|
||||
[
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "default_neurons",
|
||||
"order": 0,
|
||||
"type": "NeuronGroup",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "default_synapses",
|
||||
"order": 0,
|
||||
"type": "Synapses",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "zz_external_arrivals",
|
||||
"order": 0,
|
||||
"type": "Synapses",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"abstract_code": "not_refractory = timestep(t - lastspike, dt) >= timestep(rfc, dt)\n_g = g*exp(-dt*int(not_refractory)/tau)\n_v = g*tau*(-exp(dt*int(not_refractory)/t_mbr) + exp(dt*int(not_refractory)/tau))*exp(-dt*int(not_refractory)/t_mbr)*exp(-dt*int(not_refractory)/tau)/(t_mbr - tau) + v*exp(-dt*int(not_refractory)/t_mbr) + v_0 - v_0*exp(-dt*int(not_refractory)/t_mbr)\ng = _g\nv = _v",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # scalar code\n _vectorisation_idx = 1\n dt = _array_defaultclock_dt[0]\n _lio_1 = (- dt) / tau\n _lio_2 = exp(_lio_1)\n _lio_3 = tau / (t_mbr - tau)\n _lio_4 = dt / t_mbr\n _lio_5 = dt / tau\n _lio_6 = (- dt) / t_mbr\n _lio_7 = v_0 - v_0\n _lio_8 = v_0 - (v_0 * exp(_lio_6))\n _lio_9 = ((_lio_3 * ((- exp(_lio_4)) + exp(_lio_5))) * exp(_lio_6)) * exp(_lio_1)\n _lio_10 = exp(_lio_6)\n # vector code\n _vectorisation_idx = LazyArange(N)\n g = _array_default_neurons_g.copy()\n lastspike = _array_default_neurons_lastspike\n rfc = _array_default_neurons_rfc\n v = _array_default_neurons_v.copy()\n t = _array_defaultclock_t[0]\n not_refractory = _array_default_neurons_not_refractory.copy()\n dt = _array_defaultclock_dt[0]\n not_refractory = timestep(t - lastspike, dt) >= timestep(rfc, dt)\n _g = _numpy.where(not_refractory, _lio_2 * g, g)\n _v = _numpy.where(not_refractory, _lio_8 + ((_lio_9 * g) + (_lio_10 * v)), _lio_7 + v)\n g[not_refractory] = _g[not_refractory]\n v[not_refractory] = _v[not_refractory]\n _array_default_neurons_g[:] = g\n _array_default_neurons_not_refractory[:] = not_refractory\n _array_default_neurons_v[:] = v\n",
|
||||
"name": "default_neurons_stateupdater_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_stateupdater",
|
||||
"order": 0,
|
||||
"type": "StateUpdater",
|
||||
"when": "groups"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "oracle_common_requests",
|
||||
"order": 0,
|
||||
"type": "NetworkOperation",
|
||||
"when": "before_thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_cond = (v > v_th) and not_refractory",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _array_default_neurons__spikespace[-1] = 0\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n numpy_True = _numpy.bool_(True)\n numpy_False = _numpy.bool_(False)\n # scalar code\n _vectorisation_idx = 1\n # vector code\n _vectorisation_idx = LazyArange(N)\n not_refractory = _array_default_neurons_not_refractory\n v = _array_default_neurons_v\n _cond = (v > v_th) & not_refractory\n if _cond is True or _cond is numpy_True:\n _events = _numpy.arange(N)\n elif _cond is False or _cond is numpy_False:\n _events = _numpy.array([])\n else:\n _events, = _cond.nonzero()\n _array_default_neurons__spikespace[-1] = len(_events)\n _array_default_neurons__spikespace[:len(_events)] = _events\n # Set the neuron to refractory\n _array_default_neurons_not_refractory[_events] = False\n _array_default_neurons_lastspike[_events] = _array_defaultclock_t[0]\n",
|
||||
"name": "default_neurons_spike_thresholder_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_spike_thresholder",
|
||||
"order": 0,
|
||||
"type": "Thresholder",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _the_period = _array_zz_external_sources__period_bins[0]\n _timebin = _array_defaultclock_timestep[0]\n _n_spikes = 0\n _lastindex_before = _array_zz_external_sources__lastindex[0]\n if _the_period > 0:\n _timebin %= _the_period\n # If there is a periodicity in the SpikeGenerator, we need to reset the\n # lastindex when the period has passed\n if _lastindex_before > 0 and _array_zz_external_sources__timebins[_lastindex_before - 1] >= _timebin:\n _lastindex_before = 0\n _n_spikes = _numpy.searchsorted(_array_zz_external_sources__timebins[_lastindex_before:],\n _timebin, side='right')\n _array_zz_external_sources__lastindex[0] = _lastindex_before + _n_spikes\n _indices = _array_zz_external_sources_neuron_index[_lastindex_before:_lastindex_before+_n_spikes]\n _array_zz_external_sources__spikespace[:_n_spikes] = _indices\n _array_zz_external_sources__spikespace[-1] = _n_spikes\n",
|
||||
"name": "zz_external_sources_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "zz_external_sources",
|
||||
"order": 0,
|
||||
"type": "SpikeGeneratorGroup",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_to_record_i = _source_i\n_to_record_t = _source_t",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _n_events = _array_default_neurons__spikespace[-1]\n if _n_events > 0:\n _events = _array_default_neurons__spikespace[:_n_events]\n # Take subgroups into account\n if _source_start != 0 or _source_stop != _source_N:\n _events = _events[(_events >= _source_start) & (_events < _source_stop)]\n _n_events = len(_events)\n if _n_events > 0:\n _vectorisation_idx = 1\n _curlen = _array_spikemonitor_N[0]\n _newlen = _curlen + _n_events\n _owner.resize(_newlen)\n _array_spikemonitor_N[0] = _newlen\n _vectorisation_idx = _events\n _idx = _events\n _source_t = _array_defaultclock_t[0]\n _source_i = _array_default_neurons_i[_idx]\n _to_record_i = _source_i\n _to_record_t = _source_t\n _dynamic_array_spikemonitor_t[_curlen:_newlen] = _to_record_t\n _dynamic_array_spikemonitor_i[_curlen:_newlen] = _to_record_i\n _array_spikemonitor_count[_events - _source_start] += 1\n",
|
||||
"name": "spikemonitor_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "spikemonitor",
|
||||
"order": 1,
|
||||
"type": "SpikeMonitor",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "g += w\n",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.initialise_queue()\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.push_spikes()\n",
|
||||
"name": "default_synapses_pre_push_spikes"
|
||||
},
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _spiking_synapses = _queue.peek()\n if len(_spiking_synapses):\n # scalar code\n # vector code\n _idx = _spiking_synapses\n _vectorisation_idx = _idx\n # Abstract code: g += w\n _postsynaptic_idx = _array_default_synapses__synaptic_post[_idx]\n not_refractory = _array_default_neurons_not_refractory[_postsynaptic_idx]\n w = _array_default_synapses_w[_idx]\n _numpy.add.at(_array_default_neurons_g, _postsynaptic_idx[not_refractory], w[not_refractory])\n # Advance the spike queue\n _queue.advance()\n",
|
||||
"name": "default_synapses_pre_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "default_synapses_pre",
|
||||
"order": -1,
|
||||
"type": "SynapticPathway",
|
||||
"when": "synapses"
|
||||
},
|
||||
{
|
||||
"abstract_code": "g_post += w\n",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.initialise_queue()\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.push_spikes()\n",
|
||||
"name": "zz_external_arrivals_pre_push_spikes"
|
||||
},
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _spiking_synapses = _queue.peek()\n if len(_spiking_synapses):\n # scalar code\n # vector code\n _idx = _spiking_synapses\n _vectorisation_idx = _idx\n # Abstract code: g_post += w\n _postsynaptic_idx = _array_zz_external_arrivals__synaptic_post[_idx]\n not_refractory = _array_default_neurons_not_refractory[_postsynaptic_idx]\n w = _array_zz_external_arrivals_w[_idx]\n _numpy.add.at(_array_default_neurons_g, _postsynaptic_idx[not_refractory], w[not_refractory])\n # Advance the spike queue\n _queue.advance()\n",
|
||||
"name": "zz_external_arrivals_pre_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "zz_external_arrivals_pre",
|
||||
"order": 0,
|
||||
"type": "SynapticPathway",
|
||||
"when": "synapses"
|
||||
},
|
||||
{
|
||||
"abstract_code": "v = v_rst; w = 0; g = 0 * mV",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # scalar code\n _vectorisation_idx = 1\n w = 0\n # vector code\n _idx = _array_default_neurons__spikespace[:_array_default_neurons__spikespace[-1]]\n _vectorisation_idx = _idx\n v = v_rst\n g = 0.0\n _array_default_neurons_g[_idx] = g\n _array_default_neurons_v[_idx] = v\n",
|
||||
"name": "default_neurons_spike_resetter_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_spike_resetter",
|
||||
"order": 0,
|
||||
"type": "Resetter",
|
||||
"when": "resets"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_to_record_v = _source_v\n_to_record_g = _source_g\n_to_record_lastspike = _source_lastspike\n_to_record_not_refractory = _source_not_refractory",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # Resize dynamic arrays\n _new_len = len(_dynamic_array_oracle_end_state_t) + 1\n _owner.resize(_new_len)\n # Store values\n _dynamic_array_oracle_end_state_t[-1] = _array_defaultclock_t[0]\n # scalar code\n _vectorisation_idx = 1\n # vector code\n _vectorisation_idx = _array_oracle_end_state__indices\n _idx = _array_oracle_end_state__indices\n _source_g = _array_default_neurons_g[_idx]\n _source_not_refractory = _array_default_neurons_not_refractory[_idx]\n _source_v = _array_default_neurons_v[_idx]\n _source_lastspike = _array_default_neurons_lastspike[_idx]\n _to_record_v = _source_v\n _to_record_g = _source_g\n _to_record_lastspike = _source_lastspike\n _to_record_not_refractory = _source_not_refractory\n _dynamic_array_oracle_end_state_v[-1, :] = _to_record_v\n _dynamic_array_oracle_end_state_g[-1, :] = _to_record_g\n _dynamic_array_oracle_end_state_lastspike[-1, :] = _to_record_lastspike\n _dynamic_array_oracle_end_state_not_refractory[-1, :] = _to_record_not_refractory\n",
|
||||
"name": "oracle_end_state_codeobject"
|
||||
}
|
||||
],
|
||||
"name": "oracle_end_state",
|
||||
"order": 0,
|
||||
"type": "StateMonitor",
|
||||
"when": "end"
|
||||
}
|
||||
]
|
||||
+129
@@ -0,0 +1,129 @@
|
||||
global_neuron_idx,local_index
|
||||
-128,0
|
||||
-127,1
|
||||
-126,2
|
||||
-125,3
|
||||
-124,4
|
||||
-123,5
|
||||
-122,6
|
||||
-121,7
|
||||
-120,8
|
||||
-119,9
|
||||
-118,10
|
||||
-117,11
|
||||
-116,12
|
||||
-115,13
|
||||
-114,14
|
||||
-113,15
|
||||
-112,16
|
||||
-111,17
|
||||
-110,18
|
||||
-109,19
|
||||
-108,20
|
||||
-107,21
|
||||
-106,22
|
||||
-105,23
|
||||
-104,24
|
||||
-103,25
|
||||
-102,26
|
||||
-101,27
|
||||
-100,28
|
||||
-99,29
|
||||
-98,30
|
||||
-97,31
|
||||
-96,32
|
||||
-95,33
|
||||
-94,34
|
||||
-93,35
|
||||
-92,36
|
||||
-91,37
|
||||
-90,38
|
||||
-89,39
|
||||
-88,40
|
||||
-87,41
|
||||
-86,42
|
||||
-85,43
|
||||
-84,44
|
||||
-83,45
|
||||
-82,46
|
||||
-81,47
|
||||
-80,48
|
||||
-79,49
|
||||
-78,50
|
||||
-77,51
|
||||
-76,52
|
||||
-75,53
|
||||
-74,54
|
||||
-73,55
|
||||
-72,56
|
||||
-71,57
|
||||
-70,58
|
||||
-69,59
|
||||
-68,60
|
||||
-67,61
|
||||
-66,62
|
||||
-65,63
|
||||
-64,64
|
||||
-63,65
|
||||
-62,66
|
||||
-61,67
|
||||
-60,68
|
||||
-59,69
|
||||
-58,70
|
||||
-57,71
|
||||
-56,72
|
||||
-55,73
|
||||
-54,74
|
||||
-53,75
|
||||
-52,76
|
||||
-51,77
|
||||
-50,78
|
||||
-49,79
|
||||
-48,80
|
||||
-47,81
|
||||
-46,82
|
||||
-45,83
|
||||
-44,84
|
||||
-43,85
|
||||
-42,86
|
||||
-41,87
|
||||
-40,88
|
||||
-39,89
|
||||
-38,90
|
||||
-37,91
|
||||
-36,92
|
||||
-35,93
|
||||
-34,94
|
||||
-33,95
|
||||
-32,96
|
||||
-31,97
|
||||
-30,98
|
||||
-29,99
|
||||
-28,100
|
||||
-27,101
|
||||
-26,102
|
||||
-25,103
|
||||
-24,104
|
||||
-23,105
|
||||
-22,106
|
||||
-21,107
|
||||
-20,108
|
||||
-19,109
|
||||
-18,110
|
||||
-17,111
|
||||
-16,112
|
||||
-15,113
|
||||
-14,114
|
||||
-13,115
|
||||
-12,116
|
||||
-11,117
|
||||
-10,118
|
||||
-9,119
|
||||
-8,120
|
||||
-7,121
|
||||
-6,122
|
||||
-5,123
|
||||
-4,124
|
||||
-3,125
|
||||
-2,126
|
||||
-1,127
|
||||
|
+154
@@ -0,0 +1,154 @@
|
||||
[
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "default_neurons",
|
||||
"order": 0,
|
||||
"type": "NeuronGroup",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "default_synapses",
|
||||
"order": 0,
|
||||
"type": "Synapses",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "zz_external_arrivals",
|
||||
"order": 0,
|
||||
"type": "Synapses",
|
||||
"when": "start"
|
||||
},
|
||||
{
|
||||
"abstract_code": "not_refractory = timestep(t - lastspike, dt) >= timestep(rfc, dt)\n_g = g*exp(-dt*int(not_refractory)/tau)\n_v = g*tau*(-exp(dt*int(not_refractory)/t_mbr) + exp(dt*int(not_refractory)/tau))*exp(-dt*int(not_refractory)/t_mbr)*exp(-dt*int(not_refractory)/tau)/(t_mbr - tau) + v*exp(-dt*int(not_refractory)/t_mbr) + v_0 - v_0*exp(-dt*int(not_refractory)/t_mbr)\ng = _g\nv = _v",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # scalar code\n _vectorisation_idx = 1\n dt = _array_defaultclock_dt[0]\n _lio_1 = (- dt) / tau\n _lio_2 = exp(_lio_1)\n _lio_3 = tau / (t_mbr - tau)\n _lio_4 = dt / t_mbr\n _lio_5 = dt / tau\n _lio_6 = (- dt) / t_mbr\n _lio_7 = v_0 - v_0\n _lio_8 = v_0 - (v_0 * exp(_lio_6))\n _lio_9 = ((_lio_3 * ((- exp(_lio_4)) + exp(_lio_5))) * exp(_lio_6)) * exp(_lio_1)\n _lio_10 = exp(_lio_6)\n # vector code\n _vectorisation_idx = LazyArange(N)\n g = _array_default_neurons_g.copy()\n lastspike = _array_default_neurons_lastspike\n rfc = _array_default_neurons_rfc\n v = _array_default_neurons_v.copy()\n t = _array_defaultclock_t[0]\n not_refractory = _array_default_neurons_not_refractory.copy()\n dt = _array_defaultclock_dt[0]\n not_refractory = timestep(t - lastspike, dt) >= timestep(rfc, dt)\n _g = _numpy.where(not_refractory, _lio_2 * g, g)\n _v = _numpy.where(not_refractory, _lio_8 + ((_lio_9 * g) + (_lio_10 * v)), _lio_7 + v)\n g[not_refractory] = _g[not_refractory]\n v[not_refractory] = _v[not_refractory]\n _array_default_neurons_g[:] = g\n _array_default_neurons_not_refractory[:] = not_refractory\n _array_default_neurons_v[:] = v\n",
|
||||
"name": "default_neurons_stateupdater_codeobject_24"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_stateupdater",
|
||||
"order": 0,
|
||||
"type": "StateUpdater",
|
||||
"when": "groups"
|
||||
},
|
||||
{
|
||||
"active": true,
|
||||
"code_objects": [],
|
||||
"name": "oracle_common_requests",
|
||||
"order": 0,
|
||||
"type": "NetworkOperation",
|
||||
"when": "before_thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_cond = (v > v_th) and not_refractory",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _array_default_neurons__spikespace[-1] = 0\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n numpy_True = _numpy.bool_(True)\n numpy_False = _numpy.bool_(False)\n # scalar code\n _vectorisation_idx = 1\n # vector code\n _vectorisation_idx = LazyArange(N)\n not_refractory = _array_default_neurons_not_refractory\n v = _array_default_neurons_v\n _cond = (v > v_th) & not_refractory\n if _cond is True or _cond is numpy_True:\n _events = _numpy.arange(N)\n elif _cond is False or _cond is numpy_False:\n _events = _numpy.array([])\n else:\n _events, = _cond.nonzero()\n _array_default_neurons__spikespace[-1] = len(_events)\n _array_default_neurons__spikespace[:len(_events)] = _events\n # Set the neuron to refractory\n _array_default_neurons_not_refractory[_events] = False\n _array_default_neurons_lastspike[_events] = _array_defaultclock_t[0]\n",
|
||||
"name": "default_neurons_spike_thresholder_codeobject_24"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_spike_thresholder",
|
||||
"order": 0,
|
||||
"type": "Thresholder",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _the_period = _array_zz_external_sources__period_bins[0]\n _timebin = _array_defaultclock_timestep[0]\n _n_spikes = 0\n _lastindex_before = _array_zz_external_sources__lastindex[0]\n if _the_period > 0:\n _timebin %= _the_period\n # If there is a periodicity in the SpikeGenerator, we need to reset the\n # lastindex when the period has passed\n if _lastindex_before > 0 and _array_zz_external_sources__timebins[_lastindex_before - 1] >= _timebin:\n _lastindex_before = 0\n _n_spikes = _numpy.searchsorted(_array_zz_external_sources__timebins[_lastindex_before:],\n _timebin, side='right')\n _array_zz_external_sources__lastindex[0] = _lastindex_before + _n_spikes\n _indices = _array_zz_external_sources_neuron_index[_lastindex_before:_lastindex_before+_n_spikes]\n _array_zz_external_sources__spikespace[:_n_spikes] = _indices\n _array_zz_external_sources__spikespace[-1] = _n_spikes\n",
|
||||
"name": "zz_external_sources_codeobject_5"
|
||||
}
|
||||
],
|
||||
"name": "zz_external_sources",
|
||||
"order": 0,
|
||||
"type": "SpikeGeneratorGroup",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_to_record_i = _source_i\n_to_record_t = _source_t",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _n_events = _array_default_neurons__spikespace[-1]\n if _n_events > 0:\n _events = _array_default_neurons__spikespace[:_n_events]\n # Take subgroups into account\n if _source_start != 0 or _source_stop != _source_N:\n _events = _events[(_events >= _source_start) & (_events < _source_stop)]\n _n_events = len(_events)\n if _n_events > 0:\n _vectorisation_idx = 1\n _curlen = _array_spikemonitor_N[0]\n _newlen = _curlen + _n_events\n _owner.resize(_newlen)\n _array_spikemonitor_N[0] = _newlen\n _vectorisation_idx = _events\n _idx = _events\n _source_t = _array_defaultclock_t[0]\n _source_i = _array_default_neurons_i[_idx]\n _to_record_i = _source_i\n _to_record_t = _source_t\n _dynamic_array_spikemonitor_t[_curlen:_newlen] = _to_record_t\n _dynamic_array_spikemonitor_i[_curlen:_newlen] = _to_record_i\n _array_spikemonitor_count[_events - _source_start] += 1\n",
|
||||
"name": "spikemonitor_codeobject_1"
|
||||
}
|
||||
],
|
||||
"name": "spikemonitor",
|
||||
"order": 1,
|
||||
"type": "SpikeMonitor",
|
||||
"when": "thresholds"
|
||||
},
|
||||
{
|
||||
"abstract_code": "g += w\n",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.initialise_queue()\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.push_spikes()\n",
|
||||
"name": "default_synapses_pre_push_spikes"
|
||||
},
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _spiking_synapses = _queue.peek()\n if len(_spiking_synapses):\n # scalar code\n # vector code\n _idx = _spiking_synapses\n _vectorisation_idx = _idx\n # Abstract code: g += w\n _postsynaptic_idx = _array_default_synapses__synaptic_post[_idx]\n not_refractory = _array_default_neurons_not_refractory[_postsynaptic_idx]\n w = _array_default_synapses_w[_idx]\n _numpy.add.at(_array_default_neurons_g, _postsynaptic_idx[not_refractory], w[not_refractory])\n # Advance the spike queue\n _queue.advance()\n",
|
||||
"name": "default_synapses_pre_codeobject_24"
|
||||
}
|
||||
],
|
||||
"name": "default_synapses_pre",
|
||||
"order": -1,
|
||||
"type": "SynapticPathway",
|
||||
"when": "synapses"
|
||||
},
|
||||
{
|
||||
"abstract_code": "g_post += w\n",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.initialise_queue()\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _owner.push_spikes()\n",
|
||||
"name": "zz_external_arrivals_pre_push_spikes"
|
||||
},
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n _spiking_synapses = _queue.peek()\n if len(_spiking_synapses):\n # scalar code\n # vector code\n _idx = _spiking_synapses\n _vectorisation_idx = _idx\n # Abstract code: g_post += w\n _postsynaptic_idx = _array_zz_external_arrivals__synaptic_post[_idx]\n not_refractory = _array_default_neurons_not_refractory[_postsynaptic_idx]\n w = _array_zz_external_arrivals_w[_idx]\n _numpy.add.at(_array_default_neurons_g, _postsynaptic_idx[not_refractory], w[not_refractory])\n # Advance the spike queue\n _queue.advance()\n",
|
||||
"name": "zz_external_arrivals_pre_codeobject_5"
|
||||
}
|
||||
],
|
||||
"name": "zz_external_arrivals_pre",
|
||||
"order": 0,
|
||||
"type": "SynapticPathway",
|
||||
"when": "synapses"
|
||||
},
|
||||
{
|
||||
"abstract_code": "v = v_rst; w = 0; g = 0 * mV",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # scalar code\n _vectorisation_idx = 1\n w = 0\n # vector code\n _idx = _array_default_neurons__spikespace[:_array_default_neurons__spikespace[-1]]\n _vectorisation_idx = _idx\n v = v_rst\n g = 0.0\n _array_default_neurons_g[_idx] = g\n _array_default_neurons_v[_idx] = v\n",
|
||||
"name": "default_neurons_spike_resetter_codeobject_24"
|
||||
}
|
||||
],
|
||||
"name": "default_neurons_spike_resetter",
|
||||
"order": 0,
|
||||
"type": "Resetter",
|
||||
"when": "resets"
|
||||
},
|
||||
{
|
||||
"abstract_code": "_to_record_v = _source_v\n_to_record_g = _source_g\n_to_record_lastspike = _source_lastspike\n_to_record_not_refractory = _source_not_refractory",
|
||||
"active": true,
|
||||
"code_objects": [
|
||||
{
|
||||
"generated_code": "after_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nbefore_run:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # EMPTY_CODE_BLOCK -- overwrite in child template\nrun:\n import numpy as _numpy\n from brian2.codegen.runtime.numpy_rt.numpy_rt import LazyArange\n # Resize dynamic arrays\n _new_len = len(_dynamic_array_oracle_end_state_t) + 1\n _owner.resize(_new_len)\n # Store values\n _dynamic_array_oracle_end_state_t[-1] = _array_defaultclock_t[0]\n # scalar code\n _vectorisation_idx = 1\n # vector code\n _vectorisation_idx = _array_oracle_end_state__indices\n _idx = _array_oracle_end_state__indices\n _source_g = _array_default_neurons_g[_idx]\n _source_not_refractory = _array_default_neurons_not_refractory[_idx]\n _source_v = _array_default_neurons_v[_idx]\n _source_lastspike = _array_default_neurons_lastspike[_idx]\n _to_record_v = _source_v\n _to_record_g = _source_g\n _to_record_lastspike = _source_lastspike\n _to_record_not_refractory = _source_not_refractory\n _dynamic_array_oracle_end_state_v[-1, :] = _to_record_v\n _dynamic_array_oracle_end_state_g[-1, :] = _to_record_g\n _dynamic_array_oracle_end_state_lastspike[-1, :] = _to_record_lastspike\n _dynamic_array_oracle_end_state_not_refractory[-1, :] = _to_record_not_refractory\n",
|
||||
"name": "oracle_end_state_codeobject_1"
|
||||
}
|
||||
],
|
||||
"name": "oracle_end_state",
|
||||
"order": 0,
|
||||
"type": "StateMonitor",
|
||||
"when": "end"
|
||||
}
|
||||
]
|
||||
+48
@@ -0,0 +1,48 @@
|
||||
{
|
||||
"all_neurons_keep_original_rfc": true,
|
||||
"completeness_sha256": "847d1cf9168f7309567f41a98b9258003eb1174f46d3b61f19fab79c8a629c4f",
|
||||
"connectivity_sha256": "8e5386c56312953312d0aaef7f5d816544d859fbe66b0583ddcc2093f33c062d",
|
||||
"dt_ms": 0.1,
|
||||
"parameter_checks": {
|
||||
"membrane_tau_ms": {
|
||||
"author": 20.0,
|
||||
"case": 20.0
|
||||
},
|
||||
"refractory_ms": {
|
||||
"author": 2.2,
|
||||
"case": 2.2
|
||||
},
|
||||
"reset_potential_mv": {
|
||||
"author": -52.0,
|
||||
"case": -52.0
|
||||
},
|
||||
"resting_potential_mv": {
|
||||
"author": -52.0,
|
||||
"case": -52.0
|
||||
},
|
||||
"synaptic_delay_ms": {
|
||||
"author": 1.8,
|
||||
"case": 1.8
|
||||
},
|
||||
"synaptic_tau_ms": {
|
||||
"author": 5.0,
|
||||
"case": 5.0
|
||||
},
|
||||
"threshold_mv": {
|
||||
"author": -45.0,
|
||||
"case": -45.0
|
||||
},
|
||||
"w_syn_mv_per_anatomical_synapse": {
|
||||
"author": 0.275,
|
||||
"case": 0.275
|
||||
}
|
||||
},
|
||||
"poisson_helper_used": false,
|
||||
"precision": "float64",
|
||||
"queue_trace_enabled": false,
|
||||
"request_interface": "before_thresholds; v=v_th+1mV only if not_refractory",
|
||||
"source_parameters_modified": false,
|
||||
"source_sha256": "fc45837d7122c6ce2a7f3f2f23c515992e4b232aadb919efabb72337fac88e4e",
|
||||
"state_units": "SI volts, original dtype",
|
||||
"steps": 400
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"accepted_due_events": 0,
|
||||
"advance_calls": 0,
|
||||
"all_due_events_preserved": null,
|
||||
"due_events": 0,
|
||||
"installations": [],
|
||||
"ordering": "raw anatomical queue.peek local edge-index sequence; no sorting or filtering",
|
||||
"peek_calls": 0,
|
||||
"proxy_contract": "peek returns original object; advance and all other methods forward unchanged",
|
||||
"trace_enabled": false
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"schedule": [
|
||||
"start",
|
||||
"groups",
|
||||
"thresholds",
|
||||
"synapses",
|
||||
"resets",
|
||||
"end"
|
||||
],
|
||||
"summary": " object | part of | Clock dt | when | order | active\n------------------------------------------------+-------------------------------------------+----------------------+-------------------+-------+-------\ndefault_neurons_stateupdater (StateUpdater) | default_neurons (NeuronGroup) | 100. us (every step) | groups | 0 | yes \noracle_common_requests (NetworkOperation) | -- | 100. us (every step) | before_thresholds | 0 | yes \ndefault_neurons_spike_thresholder (Thresholder) | default_neurons (NeuronGroup) | 100. us (every step) | thresholds | 0 | yes \nzz_external_sources (SpikeGeneratorGroup) | zz_external_sources (SpikeGeneratorGroup) | 100. us (every step) | thresholds | 0 | yes \nspikemonitor (SpikeMonitor) | spikemonitor (SpikeMonitor) | 100. us (every step) | thresholds | 1 | yes \ndefault_synapses_pre (SynapticPathway) | default_synapses (Synapses) | 100. us (every step) | synapses | -1 | yes \nzz_external_arrivals_pre (SynapticPathway) | zz_external_arrivals (Synapses) | 100. us (every step) | synapses | 0 | yes \ndefault_neurons_spike_resetter (Resetter) | default_neurons (NeuronGroup) | 100. us (every step) | resets | 0 | yes \noracle_end_state (StateMonitor) | oracle_end_state (StateMonitor) | 100. us (every step) | end | 0 | yes "
|
||||
}
|
||||
Reference in New Issue
Block a user