code: def matnorm_logp_conditional_row(x, row_cov, col_cov, cond, cond_cov):
      """
      Log likelihood for centered conditional matrix-variate normal density.
  
      Consider the following partitioned matrix-normal density:
  
      .. math::
          \\begin{bmatrix}
          \\operatorname{vec}\\left[\\mathbf{X}_{i j}\\right] \\\\
          \\operatorname{vec}\\left[\\mathbf{Y}_{i k}\\right]\\end{bmatrix}
          \\sim \\mathcal{N}\\left(0,\\begin{bmatrix} \\Sigma_{j} \\otimes
          \\Sigma_{i} & \\Sigma_{j k} \\otimes \\Sigma_{i}\\\\
          \\Sigma_{k j} \\otimes \\Sigma_{i} & \\Sigma_{k} \\otimes \\Sigma_{i}
          \\end{bmatrix}\\right)
  
      Then we can write the conditional:
  
      .. math::
          \\mathbf{X}^T j i \\mid \\mathbf{Y}_{k i}^T
          \\sim \\mathcal{M}\\
          \\mathcal{N}\\left(0, \\Sigma_{j}-\\Sigma_{j k} \\Sigma_{k}^{-1}
          \\Sigma_{k j},\\
          \\Sigma_{i}\\right)
  
      This function efficiently computes the conditionals by unpacking some
      info in the covariance classes and then dispatching to
      `solve_det_conditional`.
  
      Parameters
      ---------------
      x: tf.Tensor
          Observation tensor
      row_cov: CovBase
          Row covariance (:math:`\\Sigma_{i}` in the notation above).
      col_cov: CovBase
          Column covariance (:math:`\\Sigma_{j}` in the notation above).
      cond: tf.Tensor
          Off-diagonal block of the partitioned covariance (:math:`\\Sigma_{jk}`
          in the notation above).
      cond_cov: CovBase
          Covariance of conditioning variable (:math:`\\Sigma_{k}` in the
          notation above).
  
      """
      rowsize = tf.cast(tf.shape(input=x)[0], "float64")
      colsize = tf.cast(tf.shape(input=x)[1], "float64")
  
      solve_col = col_cov.solve(tf.transpose(a=x))
      logdet_col = col_cov.logdet
  
      solve_row, logdet_row = solve_det_conditional(
          x, row_cov, cond, cond_cov
      )
  
      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 8 for calling a global function with example usage: matnorm_logp_conditional_row(x, row_cov, col_cov, cond, cond_cov) and returns: _mnorm_logp_internal