class_docstr: class to handle the context variable in the optimizer
  :param space: design space class from GPyOpt.
  :param context: dictionary of variables and their contex values
code: def __init__(self, space, context=None):
      self.space = space
      self.all_index = list(range(space.model_dimensionality))
      self.all_index_obj = list(
          range(len(self.space.config_space_expanded))
      )
      self.context_index = []
      self.context_value = []
      self.context_index_obj = []
      self.nocontext_index_obj = self.all_index_obj
      self.noncontext_bounds = self.space.get_bounds()[:]
      self.noncontext_index = self.all_index[:]
  
      if context is not None:
          ## -- Update new context
          for context_variable in context.keys():
              variable = self.space.find_variable(context_variable)
              self.context_index += variable.index_in_model
              self.context_index_obj += variable.index_in_objective
              self.context_value += variable.objective_to_model(
                  context[context_variable]
              )
  
          ## --- Get bounds and index for non context
          self.noncontext_index = [
              idx
              for idx in self.all_index
              if idx not in self.context_index
          ]
          self.noncontext_bounds = [
              self.noncontext_bounds[idx]
              for idx in self.noncontext_index
          ]
  
          ## update non context index in objective
          self.nocontext_index_obj = [
              idx
              for idx in self.all_index_obj
              if idx not in self.context_index_obj
          ]
  
file_path: GPyOpt/GPyOpt/optimization/acquisition_optimizer.py
imports: from .optimizer import OptLbfgs, OptDirect, OptCma, apply_optimizer, choose_optimizer
  from .anchor_points_generator import ObjectiveAnchorPointsGenerator, ThompsonSamplingAnchorPointsGenerator
  from ..core.task.space import Design_space
  import numpy
label_desc: Use image node_id 1 to create a new ContextManager object from inherited base classes: object with example: obj = ContextManager(space, context)