code: def matnorm_logp(x, row_cov, col_cov):
      """Log likelihood for centered matrix-variate normal density.
      Assumes that row_cov and col_cov follow the API defined in CovBase.
  
      Parameters
      ----------------
      x: tf.Tensor
          Observation tensor
      row_cov: CovBase
          Row covariance implementing the CovBase API
      col_cov: CovBase
          Column Covariance implementing the CovBase API
  
      """
  
      rowsize = tf.cast(tf.shape(input=x)[0], "float64")
      colsize = tf.cast(tf.shape(input=x)[1], "float64")
  
      # precompute sigma_col^{-1} * x'
      solve_col = col_cov.solve(tf.transpose(a=x))
      logdet_col = col_cov.logdet
  
      # precompute sigma_row^{-1} * x
      solve_row = row_cov.solve(x)
      logdet_row = row_cov.logdet
  
      return _mnorm_logp_internal(
          colsize, rowsize, logdet_row, logdet_col, solve_row, solve_col
      )
  
file_path: brainiak/brainiak/matnormal/matnormal_likelihoods.py
imports: import tensorflow
  from tensorflow import linalg
  from .utils import scaled_I
  import logging
label_desc: Use image node_id 5 for calling a global function with example usage: matnorm_logp(x, row_cov, col_cov) and returns: _mnorm_logp_internal