Hi,
the diracs correspond to incoming pre-synaptic spikes. Each spike increases instantaneously the signal s from 1 (but it is multiplied by g_ampa/nmda/gaba), which otherwise decrease using a first order equation (exponential decay).
This is already the expected behavior of spiking networks in ANNarchy, you do not need to implement the dirac function at all. Consider the following standard neuron:
IF_cond_exp = Neuron(
parameters = """
v_rest = -65.0
cm = 1.0
tau_m = 20.0
tau_syn_E = 5.0
tau_syn_I = 5.0
e_rev_E = 0.0
e_rev_I = -70.0
v_thresh = -50.0
v_reset = -65.0
i_offset = 0.0
""",
equations = """
cm * dv/dt = cm/tau_m*(v_rest -v) + g_exc * (e_rev_E - v) + g_inh * (e_rev_I - v) + i_offset : exponential, init=-65.0
tau_syn_E * dg_exc/dt = - g_exc : exponential
tau_syn_I * dg_inh/dt = - g_inh : exponential
""",
spike = "v > v_thresh",
reset = "v = v_reset",
refractory = 0.0
)
g_exc and g_inh correspond to excitatory and inhibitory conductances (ampa and gaba in your case). They decrease exponentially with time because of their respective ODE. When you create a projection to this neuron, each pre-synaptic spike will increase instantaneously the respective conductance from their synaptic efficiency (weight).
So basically, you only need to set the weights of your projection to the values of g_ampa / g_nmda / g_gaba, and directly use g_ampa / g_nmda / g_gaba inside the equation. (Note that g_ampa are reserved keywords, do not define other variables with this name!)
The NMDA synapses are a bit more complex, you can get inspiration from:
Hope that helps!
Best
Julien