Ejemplo n.º 1
0
 def __init__(self, **kwarg):
     logger.info('Initializing random settings "Contextual Synthetic ISP"')
     self.__dict__.update(kwarg)
     self.disj = False
     self.name = 'c3synthetic-isp'
     self.G = isp_net(isp_data(self.isp))
     self.arms = self.G.edges()
     self.x = {e: suni(self.d) for e in self.G.edges()}
     self.theta = suni(self.d)
     self.L = len(self.G.edges())
     self.regret_avl = True
     self.load_oracle()
     logger.info(self)
Ejemplo n.º 2
0
 def __init__(self, **kwarg):
     logger.info('Initializing random settings "Contextual Monkey"')
     self.__dict__.update(kwarg)
     self.name = 'c3synthetic-monkey'
     self.arms = list(range(self.L))
     self.x = {arm: sparse_suni(self.d, 3) for arm in self.arms}
     #self.x = {arm: np.append(sparse_suni(self.d-1, 2), [1,]) for arm in self.arms}
     self.theta = suni(self.d)
     #self.theta = np.append(suni(self.d-1)/2, [0.5,])
     self.oracle = argmax_oracle
     self.regret_avl = True
     logger.info(self)
Ejemplo n.º 3
0
 def __init__(self, **kwarg):
     logger.info('Initializing random settings "Contextual Monkey"')
     self.__dict__.update(kwarg)
     self.name = 'c3synthetic-monkey'
     self.arms = list(range(self.L))
     self.x = {arm: sparse_suni(self.d, 3) for arm in self.arms}
     #self.x = {arm: np.append(sparse_suni(self.d-1, 2), [1,]) for arm in self.arms}
     self.theta = suni(self.d)
     #self.theta = np.append(suni(self.d-1)/2, [0.5,])
     self.oracle = argmax_oracle
     self.regret_avl = True
     logger.info(self)