コード例 #1
0
 def __init__(self, n, equations, **parameters):
     threshold = brian.SimpleFunThreshold(self.check_threshold)
     reset = brian.SimpleCustomRefractoriness(IzhikevichReset(
         parameters['v_reset'], parameters['d']),
                                              period=0 * ms)
     refractory = 0 * ms
     BaseNeuronGroup.__init__(self, n, equations, threshold, reset,
                              refractory, **parameters)
コード例 #2
0
 def __init__(self, n, equations, **parameters):
     threshold = brian.SimpleFunThreshold(self.check_threshold)
     period = simplify(parameters['tau_refrac'])
     assert not hasattr(
         period, "__len__"
     ), "Brian does not support heterogenerous refractory periods with CustomRefractoriness"
     reset = brian.SimpleCustomRefractoriness(AdaptiveReset(
         parameters.pop('v_reset'), parameters.pop('b')),
                                              period=period * second)
     refractory = None
     BaseNeuronGroup.__init__(self, n, equations, threshold, reset,
                              refractory, **parameters)
コード例 #3
0
 def __init__(self, n, equations, **parameters):
     threshold = brian.SimpleFunThreshold(self.check_threshold)
     reset = brian.SimpleCustomRefractoriness(
                 IzhikevichReset(parameters['v_reset']* mV,
                               parameters['d']),
                 period=parameters['tau_refrac'].max()*ms)
     refractory = None
     BaseNeuronGroup.__init__(self, n, equations,
                              threshold, reset, refractory,
                              **parameters)
     self._variable_refractory_time = True
     self._refractory_variable = None
     self._S0 = self._S[:, 0]