class_docstr: Class to test the mapping of the objective function through the context
class_docstr_tok: ["Class","to","test","the","mapping","of","the","objective","function","through","the","context"]
code: def setUp(self):
      np.random.seed(123)
      domain = [
          {
              "name": "var1",
              "type": "continuous",
              "domain": (-5, 5),
              "dimensionality": 5,
          }
      ]
      space = Design_space(domain)
      func = alpine1(input_dim=5, bounds=space.get_bounds())
      bo = BayesianOptimization(f=func.f, domain=domain)
      context = {"var1_1": 0.3, "var1_2": 0.4}
      context_manager = ContextManager(space, context)
      x0 = np.array([[0, 0, 0, 0, 0]])
  
      # initialize the model in a least intrusive way possible
      bo.suggest_next_locations()
  
      f = bo.acquisition.acquisition_function
      f_df = bo.acquisition.acquisition_function_withGradients
      self.problem_with_context = OptimizationWithContext(
          x0=x0,
          f=f,
          df=None,
          f_df=f_df,
          context_manager=context_manager,
      )
      self.x = np.array([[3, -3, 3]])
  
file_path: GPyOpt/GPyOpt/testing/optimization_tests/test_problem_with_context.py
imports: import numpy
  import unittest
  from GPyOpt.core.task.space import Design_space
  from GPyOpt.optimization.acquisition_optimizer import ContextManager
  from GPyOpt.optimization.optimizer import OptimizationWithContext
  from GPyOpt.methods import BayesianOptimization
  from GPyOpt.objective_examples.experimentsNd import alpine1
label_desc: Use image node_id 1 for calling the TestOptimizationWithContext obj's underlying member method code with example usage: obj.setUp() without return types