3cf500d2cc6f6e783332b6b316a1973cd9b07e25,brian2/tests/test_spikegenerator.py,,test_spikegenerator_basic,#,17

Before Change


            assert all(mon[idx].v[mon.t<time] == 0)
            assert all(mon[idx].v[mon.t>=time] == 1)
        // This neuron receives two spikes
        assert all(mon[1].v[mon.t<3*ms] == 0)
        assert all(mon[1].v[(mon.t>=3*ms) & (mon.t<4*ms)] == 1)
        assert all(mon[1].v[(mon.t>=4*ms)] == 2)

After Change


        net.run(5*ms)
        for idx in xrange(5):
            generator_spikes = sorted([(idx, time) for time in times[indices==idx]])
            recorded_spikes = sorted([(idx, time) for time in s_mon.t["i==%d" % idx]])
            assert generator_spikes == recorded_spikes

@with_setup(teardown=restore_device)
def test_spikegenerator_standalone():
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: brian-team/brian2
Commit Name: 3cf500d2cc6f6e783332b6b316a1973cd9b07e25
Time: 2014-06-25
Author: marcel.stimberg@ens.fr
File Name: brian2/tests/test_spikegenerator.py
Class Name:
Method Name: test_spikegenerator_basic


Project Name: apache/incubator-mxnet
Commit Name: e2cbf6605e1a6f15777099f56821b42159605335
Time: 2020-08-12
Author: lausen@amazon.com
File Name: python/mxnet/gluon/trainer.py
Class Name: Trainer
Method Name: __init__


Project Name: mlflow/mlflow
Commit Name: 43700cb838992fddef848cff7f1a37197b035ee0
Time: 2019-05-22
Author: smurching@gmail.com
File Name: tests/store/test_sqlalchemy_store_schema.py
Class Name:
Method Name: _assert_schema_files_equal


Project Name: brian-team/brian2
Commit Name: 3cf500d2cc6f6e783332b6b316a1973cd9b07e25
Time: 2014-06-25
Author: marcel.stimberg@ens.fr
File Name: brian2/tests/test_spikegenerator.py
Class Name:
Method Name: test_spikegenerator_basic