code: def _bound_wishart(a, B, detB):
      """Returns a function of the dof, scale matrix and its determinant
      used as an upper bound in variational approximation of the evidence
      """
      n_features = B.shape[0]
      logprior = wishart_logz(a, B, detB, n_features)
      logprior -= wishart_logz(
          n_features, np.identity(n_features), 1, n_features
      )
      logprior += (
          0.5 * (a - 1) * wishart_log_det(a, B, detB, n_features)
      )
      logprior += 0.5 * a * np.trace(B)
      return logprior
  
imports: from __future__ import print_function
  import numpy
  from scipy.special import digamma, gammaln
  from scipy import linalg
  from scipy.spatial.distance import cdist
  from ..externals.six.moves import xrange
  from ..utils import check_random_state, check_array, deprecated
  from ..utils.extmath import logsumexp, pinvh, squared_norm
  from ..utils.validation import check_is_fitted
  from ..None import cluster
  from .gmm import _GMMBase
label_desc: Use image node_id 6 for calling a global function with example usage: _bound_wishart(a, B, detB) and returns: logprior