code: def _get_gp_ucb_dim(gp):
      """Returns the dimensionality of the dimension."""
      if hasattr(gp, "ucb_dim") and gp.ucb_dim is not None:
          return gp.ucb_dim
      elif hasattr(gp.kernel, "dim"):
          return gp.kernel.dim
      else:
          return 3.0
  
imports: from __future__ import division
  from argparse import Namespace
  from copy import copy
  import numpy
  from scipy.stats import norm
  from ..utils.general_utils import solve_lower_triangular
  from ..gp.gp_core import get_post_covar_from_raw_covar
  from ..exd.domains import EuclideanDomain
  from ..exd.exd_utils import maximise_with_method
label_desc: Use image node_id 11 for calling a global function with example usage: _get_gp_ucb_dim(gp) and returns: gp, gp, int