class_docstr: Main class to initialize a Bayesian Optimization method.
  :param f: function to optimize. It should take 2-dimensional numpy arrays as input and return 2-dimensional outputs (one evaluation per row).
  :param domain: list of dictionaries containing the description of the inputs variables (See GPyOpt.core.task.space.Design_space class for details).
  :param constraints: list of dictionaries containing the description of the problem constraints (See GPyOpt.core.task.space.Design_space class for details).
  :cost_withGradients: cost function of the objective. The input can be:
      - a function that returns the cost and the derivatives and any set of points in the domain.
      - 'evaluation_time': a Gaussian process (mean) is used to handle the evaluation cost.
  :model_type: type of model to use as surrogate:
      - 'GP', standard Gaussian process.
      - 'GP_MCMC', Gaussian process with prior in the hyper-parameters.
      - 'sparseGP', sparse Gaussian process.
      - 'warperdGP', warped Gaussian process.
      - 'InputWarpedGP', input warped Gaussian process
      - 'RF', random forest (scikit-learn).
  :param X: 2d numpy array containing the initial inputs (one per row) of the model.
  :param Y: 2d numpy array containing the initial outputs (one per row) of the model.
  :initial_design_numdata: number of initial points that are collected jointly before start running the optimization.
  :initial_design_type: type of initial design:
      - 'random', to collect points in random locations.
      - 'latin', to collect points in a Latin hypercube (discrete variables are sampled randomly.)
  :acquisition_type: type of acquisition function to use.
      - 'EI', expected improvement.
      - 'EI_MCMC', integrated expected improvement (requires GP_MCMC model).
      - 'MPI', maximum probability of improvement.
      - 'MPI_MCMC', maximum probability of improvement (requires GP_MCMC model).
      - 'LCB', GP-Lower confidence bound.
      - 'LCB_MCMC', integrated GP-Lower confidence bound (requires GP_MCMC model).
  :param normalize_Y: whether to normalize the outputs before performing any optimization (default, True).
  :exact_feval: whether the outputs are exact (default False).
  :acquisition_optimizer_type: type of acquisition function to use.
      - 'lbfgs', L-BFGS.
      - 'DIRECT', Dividing Rectangles.
      - 'CMA', covariance matrix adaptation.
  :param model_update_interval: interval of collected observations after which the model is updated (default, 1).
  :param evaluator_type: determines the way the objective is evaluated (all methods are equivalent if the batch size is one)
      - 'sequential', sequential evaluations.
      - 'random', synchronous batch that selects the first element as in a sequential policy and the rest randomly.
      - 'local_penalization', batch method proposed in (Gonzalez et al. 2016).
      - 'thompson_sampling', batch method using Thompson sampling.
  :param batch_size: size of the batch in which the objective is evaluated (default, 1).
  :param num_cores: number of cores used to evaluate the objective (default, 1).
  :param verbosity: prints the models and other options during the optimization (default, False).
  :param maximize: when True -f maximization of f is done by minimizing -f (default, False).
  :param **kwargs: extra parameters. Can be used to tune the current optimization setup or to use deprecated options in this package release.
  
  
  .. Note::   The parameters bounds, kernel, numdata_initial_design, type_initial_design, model_optimize_interval, acquisition, acquisition_par
              model_optimize_restarts, sparseGP, num_inducing and normalize can still be used but will be deprecated in the next version.
class_docstr_tok: ["Main","class","to","initialize","a","Bayesian","Optimization","method",".",":","param","f",":","function","to","optimize",".","It","should","take","2-dimensional","numpy","arrays","as","input","and","return","2-dimensional","outputs","(","one","evaluation","per","row",")",".",":","param","domain",":","list","of","dictionaries","containing","the","description","of","the","inputs","variables","(","See","GPyOpt.core.task.space.Design_space","class","for","details",")",".",":","param","constraints",":","list","of","dictionaries","containing","the","description","of","the","problem","constraints","(","See","GPyOpt.core.task.space.Design_space","class","for","details",")",".",":","cost_withGradients",":","cost","function","of","the","objective",".","The","input","can","be",":","-","a","function","that","returns","the","cost","and","the","derivatives","and","any","set","of","points","in","the","domain",".","-","'evaluation_time","'",":","a","Gaussian","process","(","mean",")","is","used","to","handle","the","evaluation","cost",".",":","model_type",":","type","of","model","to","use","as","surrogate",":","-","'GP","'",",","standard","Gaussian","process",".","-","'GP_MCMC","'",",","Gaussian","process","with","prior","in","the","hyper-parameters",".","-","'sparseGP","'",",","sparse","Gaussian","process",".","-","'warperdGP","'",",","warped","Gaussian","process",".","-","'InputWarpedGP","'",",","input","warped","Gaussian","process","-","'RF","'",",","random","forest","(","scikit-learn",")",".",":","param","X",":","2d","numpy","array","containing","the","initial","inputs","(","one","per","row",")","of","the","model",".",":","param","Y",":","2d","numpy","array","containing","the","initial","outputs","(","one","per","row",")","of","the","model",".",":","initial_design_numdata",":","number","of","initial","points","that","are","collected","jointly","before","start","running","the","optimization",".",":","initial_design_type",":","type","of","initial","design",":","-","'random","'",",","to","collect","points","in","random","locations",".","-","'latin","'",",","to","collect","points","in","a","Latin","hypercube","(","discrete","variables","are","sampled","randomly",".",")",":","acquisition_type",":","type","of","acquisition","function","to","use",".","-","'EI","'",",","expected","improvement",".","-","'EI_MCMC","'",",","integrated","expected","improvement","(","requires","GP_MCMC","model",")",".","-","'MPI","'",",","maximum","probability","of","improvement",".","-","'MPI_MCMC","'",",","maximum","probability","of","improvement","(","requires","GP_MCMC","model",")",".","-","'LCB","'",",","GP-Lower","confidence","bound",".","-","'LCB_MCMC","'",",","integrated","GP-Lower","confidence","bound","(","requires","GP_MCMC","model",")",".",":","param","normalize_Y",":","whether","to","normalize","the","outputs","before","performing","any","optimization","(","default",",","True",")",".",":","exact_feval",":","whether","the","outputs","are","exact","(","default","False",")",".",":","acquisition_optimizer_type",":","type","of","acquisition","function","to","use",".","-","'lbfgs","'",",","L-BFGS",".","-","'DIRECT","'",",","Dividing","Rectangles",".","-","'CMA","'",",","covariance","matrix","adaptation",".",":","param","model_update_interval",":","interval","of","collected","observations","after","which","the","model","is","updated","(","default",",","1",")",".",":","param","evaluator_type",":","determines","the","way","the","objective","is","evaluated","(","all","methods","are","equivalent","if","the","batch","size","is","one",")","-","'sequential","'",",","sequential","evaluations",".","-","'random","'",",","synchronous","batch","that","selects","the","first","element","as","in","a","sequential","policy","and","the","rest","randomly",".","-","'local_penalization","'",",","batch","method","proposed","in","(","Gonzalez","et","al",".","2016",")",".","-","'thompson_sampling","'",",","batch","method","using","Thompson","sampling",".",":","param","batch_size",":","size","of","the","batch","in","which","the","objective","is","evaluated","(","default",",","1",")",".",":","param","num_cores",":","number","of","cores","used","to","evaluate","the","objective","(","default",",","1",")",".",":","param","verbosity",":","prints","the","models","and","other","options","during","the","optimization","(","default",",","False",")",".",":","param","maximize",":","when","True","-f","maximization","of","f","is","done","by","minimizing","-f","(","default",",","False",")",".",":","param","*","*","kwargs",":","extra","parameters",".","Can","be","used","to","tune","the","current","optimization","setup","or","to","use","deprecated","options","in","this","package","release",".","..","Note",":",":","The","parameters","bounds",",","kernel",",","numdata_initial_design",",","type_initial_design",",","model_optimize_interval",",","acquisition",",","acquisition_par","model_optimize_restarts",",","sparseGP",",","num_inducing","and","normalize","can","still","be","used","but","will","be","deprecated","in","the","next","version","."]
code: def _model_chooser(self):
      return self.problem_config.model_creator(
          self.model_type, self.exact_feval, self.space
      )
  
imports: from ..acquisitions import AcquisitionEI, AcquisitionMPI, AcquisitionLCB, AcquisitionEI_MCMC, AcquisitionMPI_MCMC, AcquisitionLCB_MCMC, AcquisitionLP, AcquisitionEntropySearch
  from ..core.bo import BO
  from ..core.errors import InvalidConfigError
  from ..core.task.space import Design_space, bounds_to_space
  from ..core.task.objective import SingleObjective
  from ..core.task.cost import CostModel
  from ..experiment_design import initial_design
  from ..util.arguments_manager import ArgumentsManager
  from ..core.evaluators import Sequential, RandomBatch, LocalPenalization, ThompsonBatch
  from ..models.gpmodel import GPModel, GPModel_MCMC
  from ..models.rfmodel import RFModel
  from ..models.warpedgpmodel import WarpedGPModel
  from ..models.input_warped_gpmodel import InputWarpedGPModel
  from ..optimization.acquisition_optimizer import AcquisitionOptimizer
  import GPyOpt
  import warnings
label_desc: Use image node_id 2 for calling the BayesianOptimization obj's underlying member method code with example usage: obj._model_chooser() and returns: self