Esempio n. 1
0
 def __init__(self, TNode=None):
     self.__NodeWeight = SharedCounter.WEIGHT_START
     self.__NodeInput = None
     self.__Bais = random.uniform( SharedCounter.INITIAL_BAIS, SharedCounter.alpha)
     self.TNode = TNode
     self.LocalMax_Index = 0
     self.LocalMin_Index = 0
     self.LocalMax_Activation = 0
     self.LocalMin_Activation = 1
     Properties.__init__(self)
     Identity.__init__(self)
    def __init__(self, **kwargs):
        Identity.__init__(self)
        Container.__init__(self)
        NodeGraph.__init__(self)
        Position.__init__(self)

        self.NumTNode = kwargs.get('NumTNode')
        self.pass_counter = 1

        attr = SharedCounter.Counter
        for _ in range(attr, self.NumTNode + 1):  # For all tensors
            newTensor = TNode(layer=self)  # Create a new instance of tensor
            self.add(newTensor)  # add tensor in Container
    def __init__(self, **kwargs):
        '''Pass NumLayer=?,NumTensor=?'''

        Identity.__init__(self)
        Container.__init__(self)
        Position.__init__(self)

        self.NumLayers = kwargs.get('NumLayer')
        self.NumTensor = kwargs.get('NumTensor')
        self._Data = None
        # Model Initilization by private functions
        self.__InitLayers()
        self.__ConnectLayers()
        self.__ConnectTensors()
        self.__ConnectWeightsOfTensor()
 def __init__(self, layer=None):
     #id class
     Identity.__init__(self)
     #A wraped graph instance
     NodeGraph.__init__(self)
     #A position identifier
     Position.__init__(self)
     #A wraped weight dictionary
     WeightDict.__init__(self)
     #Node input class
     _Activation.__init__(self, SharedCounter.INITIAL_ACTIVATION)
     #Node Bais class
     _Bais.__init__(self, SharedCounter.INITIAL_BAIS)
     #Activation function , set at time of model init.
     _ActivationFn.__init__(self)
     #properties for each tnode, for different optimizing algorithms.
     Properties.__init__(self)
     self.Layer = layer
Esempio n. 5
0
	def __init__( self, x , y) :
		Identity.__init__(self, "Door", '+',x, y, 1, 1)
		self.isConnected = False
Esempio n. 6
0
	def __init__( self, type, character, x, y, nbLife) :
		Identity.__init__(self, type, character, x, y, 1, 1)
		self.nbLife = nbLife
Esempio n. 7
0
	def __init__ ( self, x, y, size_x, size_y) :
		Identity.__init__(self, "Room",'.', x, y, size_x, size_y)
		self.nbDoor = random.randint(1, 3)
		self.door = []
		self.generateDoors()
Esempio n. 8
0
	def __init__(self, sz_x, sz_y):
		Identity.__init__(self, "Map", ' ', 0, 0, sz_x, sz_y)
		self.room = []
		self.corridor = []