class_docstr: Subclass of Bayesian GMMs (BGMM)
  that implements Variational Bayes estimation of the parameters
class_docstr_tok: ["Subclass","of","Bayesian","GMMs","(","BGMM",")","that","implements","Variational","Bayes","estimation","of","the","parameters"]
docstr: VB-E step
  
  Parameters
  ----------
  x array of shape (nb_samples,dim)
    the data used in the estimation process
  
  Returns
  -------
  like: array of shape(nb_samples,self.k),
        component-wise likelihood
docstr_tok: ["VB-E","step","Parameters","--","--","--","--","--","x","array","of","shape","(","nb_samples",",","dim",")","the","data","used","in","the","estimation","process","Returns","--","--","--","-","like",":","array","of","shape","(","nb_samples",",","self.k",")",",","component-wise","likelihood"]
code: def _Estep(self, x):
      """VB-E step
  
      Parameters
      ----------
      x array of shape (nb_samples,dim)
        the data used in the estimation process
  
      Returns
      -------
      like: array of shape(nb_samples,self.k),
            component-wise likelihood
      """
      n = x.shape[0]
      like = np.zeros((n, self.k))
      from scipy.special import psi
  
      spsi = psi(np.sum(self.weights))
      for k in range(self.k):
          # compute the data-independent factor first
          w0 = psi(self.weights[k]) - spsi
          w0 += 0.5 * np.log(detsh(self.scale[k]))
          w0 -= self.dim * 0.5 / self.shrinkage[k]
          w0 += 0.5 * np.log(2) * self.dim
          for i in range(self.dim):
              w0 += 0.5 * psi((self.dof[k] - i) / 2)
          m = np.reshape(self.means[k], (1, self.dim))
          b = self.dof[k] * self.scale[k]
          q = np.sum(np.dot(m - x, b) * (m - x), 1)
          w = w0 - q / 2
          w -= 0.5 * np.log(2 * np.pi) * self.dim
          like[:, k] = np.exp(w)
  
      if like.min() < 0:
          raise ValueError("Likelihood cannot be negative")
      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 2 for calling the VBGMM obj's underlying member method code with example usage: obj._Estep(x) and returns: like