bug fix iaf_psc_exp_multisynapse / sli2py test_iaf_psc_exp_multisynapse#2986
bug fix iaf_psc_exp_multisynapse / sli2py test_iaf_psc_exp_multisynapse#2986heplesser merged 22 commits intonest:masterfrom
Conversation
heplesser
left a comment
There was a problem hiding this comment.
@janskaar Good catch! I have an alternative solution for summing the currents and some suggestions for the tests. The same problem applies to iaf_psc_alpha_multisynapse. I think it would be a good idea to fix both neurons within this PR.
heplesser
left a comment
There was a problem hiding this comment.
The new test should got to pytest/sli2py_models.
Co-authored-by: Hans Ekkehard Plesser <hans.ekkehard.plesser@nmbu.no>
Co-authored-by: Hans Ekkehard Plesser <hans.ekkehard.plesser@nmbu.no>
Co-authored-by: Hans Ekkehard Plesser <hans.ekkehard.plesser@nmbu.no>
Co-authored-by: Hans Ekkehard Plesser <hans.ekkehard.plesser@nmbu.no>
… into sli2py_iaf_psc_exp_multisynapse
Co-authored-by: Hans Ekkehard Plesser <hans.ekkehard.plesser@nmbu.no>
…multisynapse' into sli2py_iaf_psc_exp_multisynapse
Formatting should be fixed now. The alpha multisynapse test was merged a couple of weeks ago, but I have updated it to be more in line with this one now. |
|
@heplesser Sorry, just noticed that test_mini_brunel_ps.sli fails, but only on MacOS. Have you encountered something like this before? It's for a completely different neuron model, so it's difficult to see why it should fail here. |
|
|
@otcathatsya Ping! |
otcathatsya
left a comment
There was a problem hiding this comment.
Looks good! Do we have a preference for which approximate comparison method to use? We have quite a few pytest.approx and I just saw that numpy's assert_almost_equal works with absolute decimal places instead, though in this case they'd work interchangeably too.
I don't think we have made a definite decision. I am not certain how pytest.approx works on NumPy arrays, because |
Before, S_.current_ was computed before the updating individual synaptic ports, causing them to be 1 time step behind. Additionally, it was only computed when the neuron was not refractory, while the individual synaptic ports were updated every time step. Moving the S_.current_ computation down a few lines fixes this.
Port test_iaf_psc_exp_multisynapse.sli to py