docs: def gradF_t(X, Y, S, M_E, E, m0, rho):
      ''' Compute the gradient.
      '''
      n, r = X.shape
      m, r = Y.shape
  
      XS = np.dot(X, S)
      YS = np.dot(Y, S.T)
      XSY = np.dot(XS, Y.T)
  
      Qx = np.dot(np.dot(X.T, ((M_E - XSY) * E)), YS) / n
      Qy = np.dot(np.dot(Y.T, ((M_E - XSY) * E).T), XS) / m
  
      W = np.dot((XSY - M_E) * E, YS) + np.dot(X, Qx) + rho * Gp(X, m0, r)
      Z = np.dot(((XSY - M_E) * E).T, XS) + np.dot(Y, Qy) + rho * Gp(Y, m0, r)
  
      return W, Z