code: def normal_eval(mu, P, x, dP=None):
      """Probability of x under normal(mu, inv(P))
  
      Parameters
      ----------
      mu: array of shape (n),
          the mean parameter
      P: array of shape (n, n),
         the precision matrix
      x: array of shape (n),
         the data to be evaluated
  
      Returns
      -------
      (float) the density
      """
      dim = P.shape[0]
      if dP is None:
          dP = detsh(P)
  
      w0 = math.log(dP) - dim * math.log(2 * math.pi)
      w0 /= 2
      dx = mu - x
      q = np.dot(np.dot(P, dx), dx)
      w = w0 - q / 2
      like = math.exp(w)
      return like
  
imports: import math
  import numpy
  import numpy.random
  from scipy.linalg import cholesky, eigvalsh, inv
  from scipy.special import gammaln
  from .gmm import GMM
  from .utils import kmeans
label_desc: Use image node_id 6 for calling a global function with example usage: normal_eval(mu, P, x, dP) and returns: like