Exemple #1
0
    def __init__(self, *args, **kwargs):
        super(TimedFileStrategy, self).__init__([], [])

        self.posFile = kwargs.get('posFile', None)

        if self.posFile is None:
            raise Exception('Need a posFile')

        ff = open(self.posFile)
        self.timesAndPositions = readArray(ff)
        ff.close()

        self.times = self.timesAndPositions[:,0]
        self.positions = self.timesAndPositions[:,1:]

        self.separateLogInfo = True
        
        self.counter = 0
Exemple #2
0
    def __init__(self, *args, **kwargs):
        super(FileStrategy, self).__init__([], [])

        self.filtFile = kwargs.get('filtFile', None)

        if self.filtFile is None:
            raise Exception('Need a filtFile')

        ff = open(self.filtFile)
        self.positions = readArray(ff)
        ff.close()

        TOTAL_TIME = 12
        self.times = linspace(0, TOTAL_TIME, self.positions.shape[0])

        self.separateLogInfo = True
        
        self.counter = 0
    def __init__(self, *args, **kwargs):
        super(FileStrategy, self).__init__([], [])

        self.filtFile = kwargs.get('filtFile', None)

        self.junkPoints      = 1000
        # How many lines to expect from HyperNEAT file
        self.expectedLines   = self.junkPoints + 12 * 40


        if self.filtFile is None:
            raise Exception('Need a filtFile')

        ff = open(self.filtFile)
        self.positions = readArray(ff)
        ff.close()

        TOTAL_TIME = 12
        self.times = linspace(0, TOTAL_TIME, self.positions.shape[0])

        self.separateLogInfo = True
        
        self.counter = 0