60 def parameters(self,params):
64 def lower_bound(self):
68 def lower_bound(self,lb):
72 def upper_bound(self):
76 def upper_bound(self,ub):
82 raise NotImplementedError(
"Please Implement this method")
90 return min_val, x_out, error
104 def __init__(self, x_set=None, n_dim=None, n_samples=None):
109 if n_dim
is None or n_samples
is None:
112 self.
x_set = np.random.rand(n_samples, n_dim)
115 def parameters(self):
119 def parameters(self,params):
126 raise NotImplementedError(
"Please Implement this method")
134 return min_val, x_out, error
154 def parameters(self):
158 def parameters(self,params):
165 raise NotImplementedError(
"Please Implement this method")
169 min_val, x_out, error = bo.optimize_categorical(self.
evaluateSample,
173 return min_val, x_out, error
177 if __name__ ==
"__main__":
179 __value__, __x__, __err__ = BO.optimize()
180 print(
"Result", __x__)
params
Library parameters.
def optimize(self)
Main function.
def evaluateSample(self, x_in)
Function for testing.
def __init__(self, categories=None)
Let's define the parameters.
def evaluateSample(self, x_in)
Function for testing.
def __init__(self, n_dim)
Let's define the parameters.
def __init__(self, x_set=None, n_dim=None, n_samples=None)
Let's define the parameters.
x_set
Set of discrete points.
Python Module for BayesOptCategorical.
def optimize(self)
Main function.
Python Module for BayesOptDiscrete.
def evaluateSample(self, x_in)
Function for testing.
Python Module for BayesOptContinuous.
def optimize(self)
Main function.
params
Library parameters.
params
Library parameters.