예제 #1
0
 def __init__(self, name, **kw):
     Cell.__init__(self, name)
     self.cellDim = kw.get('dimension', 3)   # dimension of finite element cell
     self.degree = kw.get('degree', 1)       # degree of finite-element cell
     self.order = kw.get('order', -1)        # order of finite-element cell
     self.configure()
     return
    def __init__(self, drug=True):
        """ Object initialization.

		Keyword arguments:
		drug -- A boolean flag that is used to decide whether 5-HT is
		inserted in the model or not (default = True).
		"""

        Cell.__init__(self)

        # Define parameters
        self._drug = drug
        self.synapses = []
        self._nNodes = 41
        self._nDendrites = 12
        self._diamAxon = 8.74

        # dendrite diameters scaled for the rat
        self._diamDend = [
            1.5277386855568675e+01, 1.7434194411648960e+01,
            1.9770735930735935e+01, 1.7973396300669030e+01,
            1.7613928374655650e+01, 1.6355790633608819e+01,
            1.4378717040535225e+01, 1.2940845336481701e+01,
            1.0424569854388038e+01, 8.5373632428177881e+00,
            6.7400236127508864e+00, 3.1453443526170801e+00
        ]
        # dendrite length
        self._lengthDend = [
            5.0e+02, 5.0e+02, 7.0e+02, 9.0e+02, 5.0e+02, 4.0e+02, 6.0e+02,
            4.0e+02, 5.0e+02, 5.0e+02, 5.0e+02, 5.0e+02
        ]

        self._create_sections()
        self._define_biophysics()
        self._build_topology()
예제 #3
0
 def __init__(self, name, **kw):
     Cell.__init__(self, name)
     self.cellDim = kw.get('dimension',
                           3)  # dimension of finite element cell
     self.degree = kw.get('degree', 1)  # degree of finite-element cell
     self.order = kw.get('order', -1)  # order of finite-element cell
     self.configure()
     return
예제 #4
0
 def __init__(self, x, y, state, cx, cy):
     Cell.__init__(self, x, y, state)
     pygame.sprite.Sprite.__init__(self)
     self.image = pygame.Surface((self.size, self.size))
     self.rect = self.image.get_rect()
     self.cx = cx
     self.cy = cy
     self._draw()
예제 #5
0
    def __init__(self):
        """ Object initialization. """
        Cell.__init__(self)

        #Create IntFire4
        self.cell = h.IntFire4()
        self.cell.taue = 0.5
        self.cell.taui1 = 5
        self.cell.taui2 = 10
        self.cell.taum = 30  #0.2 nF divided g 20 nS
예제 #6
0
파일: Agent.py 프로젝트: agoryu/SCI
 def __init__(self, x, y, pasX, pasY):
     """
     Construit un agent simple, pour une bille.
     @param x: position en x
     @param y: position en y
     @param pasX: le déplacement en x
     @param pasY: le déplacement en y
     """
     Cell.__init__(self,x,y)
     
     self.pasX = int(pasX)
     self.pasY = int(pasY)
     self.color = choice(['blue', 'red', 'green', 'magenta'])
예제 #7
0
    def __init__(self):
        """ Object initialization. """
        Cell.__init__(self)

        noisePerc = 0.05

        #Create IntFire4
        self.cell = h.IntFireMn()
        self.cell.taue = 0.25
        self.cell.taui1 = 2
        self.cell.taui2 = 4.5
        self.cell.taum = rnd.normalvariate(6, 6 * noisePerc)
        if self.cell.taum <= self.cell.taui2:
            self.cell.taum = self.cell.taui2 + 0.25
        self.cell.refrac = rnd.normalvariate(20, 20 * noisePerc)  # mean 50Hz
    def __init__(self, delay):
        """ Object initialization.

		Keyword arguments:
		delay -- time delay in ms needed by a spike to travel the whole fiber
		"""

        Cell.__init__(self)
        self._debug = False

        #Initialise cell parameters
        self._set_delay(delay)

        self.maxFiringRate = 200  # This should be lower than the frequency allowed by the refractory period
        self._maxSensorySpikesXtime = int(
            float(self._delay) / 1000. * float(self.maxFiringRate) + 2)
        self._maxEesSpikesXtime = int(
            float(self._delay) / 1000. *
            float(self.__class__.__maxEesFrequency) + 2)
        #Mean refractory period of 1.6 ms - 625 Hz
        noisePerc = 0.1
        self._refractoryPeriod = rnd.normalvariate(1.6, 1.6 * noisePerc)
        if self._refractoryPeriod > 1000. / self.maxFiringRate:
            self._refractoryPeriod = 1000. / self.maxFiringRate
            print "Warning: refractory period bigger than period between 2 natural pulses"
        #Position along the fiber recruited by the stimulation
        self._stimPosition = self._delay - 0.5

        self.initialise()
        #Create an ARTIFICIAL_CELL Neuron mechanism that will be the source of a netCon object.
        #This will be used to comunicate the APs to target cells
        self.cell = h.AfferentFiber()

        #Create a netcon to make the fiber fire
        self._fire = h.NetCon(None, self.cell)

        # Boolean flag to record a segment of the fiber over time
        self._record = False
 def __init__(self, width, height, color, grid):
     Cell.__init__(self, width, height, grid.margin)
     self.color = color
     self.grid = grid
     self.setup()
 def __init__(self,width,height,color,grid):
     Cell.__init__(self,width,height,grid.margin)
     self.color = color
     self.grid = grid
     self.setup()
예제 #11
0
 def __init__(self, position=None):
     Cell.__init__(self, position)
예제 #12
0
 def __init__(self, name, **kw):
     Cell.__init__(self, name)
     self.degree = kw.get('degree', 1)
     self.order = kw.get('order', -1)
     self.configure()
     return
예제 #13
0
 def __init__(self, name, **kw):
     Cell.__init__(self, name)
     self.degree = kw.get('degree', 1)
     self.order = kw.get('order', -1)
     self.configure()
     return
 def __init__(self, rigidBody, replacingCell, x, y):
     Cell.__init__(self, x, y)
     self.replacingCell = replacingCell