Skip to content

Commit 23eb7ed

Browse files
committed
minor mod to lif
1 parent 2189f51 commit 23eb7ed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ngclearn/components/neurons/spiking/LIFCell.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ def _advance_state(t, dt, tau_m, R_m, v_rest, v_reset, v_decay, refract_T,
277277
thr_theta = _update_theta(dt, thr_theta, raw_spikes, tau_theta, theta_plus)
278278
## update tols
279279
tols = _update_times(t, s, tols)
280-
return v, s, raw_spikes, rfr, thr_theta, tols, key, surrogate
280+
return jnp.maximum(v, v_rest), s, raw_spikes, rfr, thr_theta, tols, key, surrogate
281281

282282
@resolver(_advance_state)
283283
def advance_state(self, v, s, s_raw, rfr, thr_theta, tols, key, surrogate):

0 commit comments

Comments
 (0)