def __init__(self, conf): Metamodel.__init__(self) self.conf = conf self.interpolators = [] for m in self.conf.modules: self.interpolators.append(LinearRegression()) self.inputs = [] self.outputs =[]
def __init__(self, conf): Metamodel.__init__(self) self.conf = conf self.svrs = [] self.inputs = [] self.outputs = [] for m in conf.modules: #self.svrs.append(SVR(kernel='rbf', C=1e3, gamma=0.1)) self.svrs.append(SVR(kernel='linear', C=1.0)) self.inputs.append([]) self.outputs.append([])
def __init__(self, conf): Metamodel.__init__(self) self.conf = conf self.ds = [] self.nets = [] self.trainers = [] for m in conf.modules: input = conf.modNum output = 1 self.ds.append(SupervisedDataSet(input, output)) self.nets.append(buildNetwork(input, 1, output, hiddenclass=LinearLayer, outclass=LinearLayer)) self.trainers.append(RPropMinusTrainer(self.nets[len(self.nets)-1]))
def __init__(self): Metamodel.__init__(self)
def add(self, system): if not Metamodel.add(self, system): return
def add(self, system): if not Metamodel.add(self, system): return for m in system.modules: self.ds[m.num].addSample(self.sys2array(system), m.time)
def add(self, system): Metamodel.add(self, system)
def add(self, system): if not Metamodel.add(self, system): return for m in system.modules: self.inputs[m.num].append(self.sys2array(system)) self.outputs[m.num].append(m.time)
def __init__(self,k): Metamodel.__init__(self) self.k = k