def __init__(self, surrogate, acquisition_params, n_dims, n_iter=50, max_iter=1E5):
        """
        Parameters
        ----------
        surrogate : a surrogate function which can has defined on it:
              - surrogate.predict(X) for predicting the mean and variance of the model at X
              # TODO make this the mean response, not the max of the data
              - surrogate.Y.max() for calculating the incumbent
        # TODO make this come from the surrogate, along with what type of parameter each dimension represents
        n_dims : the number of dimensions
        # TODO Decide where to put defaults - at the moment it's in the Bayesian strategy class
        acquisition_params : dictionary of acquisition function options
        n_iter : the optimizer is run this many times with different random seeds - the optimum
            is chosen from this many candidates.
        max_iter : the maximum number of iterations used the optimizer (for a single run of the optimizer)
        """
        if not minimize:
            raise ImportError('No module named SciPy')

        self.surrogate = surrogate
        self.n_dims = n_dims
        self.n_iter = n_iter
        self.max_iter = max_iter
        self.acquisition_params = acquisition_params
        self._acquisition_function = None
        self._set_acquisition()
        self.incumbent = None
def __init__ ( self , surrogate , acquisition_params , n_dims , n_iter = 50 , max_iter = 1E5 ) : if not minimize : raise ImportError ( 'No module named SciPy' ) self . surrogate = surrogate self . n_dims = n_dims self . n_iter = n_iter self . max_iter = max_iter self . acquisition_params = acquisition_params self . _acquisition_function = None self . _set_acquisition ( ) self . incumbent = None
Parameters
        ----------
        surrogate : a surrogate function which can has defined on it:
              - surrogate.predict(X) for predicting the mean and variance of the model at X
              # TODO make this the mean response, not the max of the data
              - surrogate.Y.max() for calculating the incumbent
        # TODO make this come from the surrogate, along with what type of parameter each dimension represents
        n_dims : the number of dimensions
        # TODO Decide where to put defaults - at the moment it's in the Bayesian strategy class
        acquisition_params : dictionary of acquisition function options
        n_iter : the optimizer is run this many times with different random seeds - the optimum
            is chosen from this many candidates.
        max_iter : the maximum number of iterations used the optimizer (for a single run of the optimizer)