Expand description
Step-by-step parity with PINGCircuit.step in
src/sc_neurocore/network/gamma_oscillation.py.
Per dt:
- Decay AMPA / GABA conductances by
exp(-dt/tau_*). - Compute
I = -g_L*(V-E_L) - g_AMPA*(V-E_AMPA) - g_GABA*(V-E_GABA) + I_drive + sqrt(dt)*sigma*xi. (xiis supplied externally as a pre-drawn N(0,1) array so the Rust path stays bit-deterministic for matching seeds — seetests/test_gamma_oscillation.py::TestPINGCircuitDeterminism.) - Update
VEuler-style; cells in refractory are clamped to V_reset. - Detect spikes (
V >= V_th, not in refractory). - Reset spiked cells to V_reset, start refractory window.
- Decrement refractory counters; clamp to 0.
- Return per-cell spike booleans + total per-population spike counts so the Python wrapper can propagate to conductances.
This is the kernel for the per-step inner loop. The Python side still owns:
- the per-instance RNG (so noise stays seed-deterministic across the two backends);
- the cross-population conductance update step (g_ampa_e += w_ee * n_e_spikes etc — handled by the caller).