def _bound_wishart(a, B, detB):
 n_features = B.shape[0]
 logprior = wishart_logz(a, B, detB, n_features)
 logprior -= wishart_logz(n_features, np.identity(n_features), 1, n_features)
 logprior += ((0.5 * (a - 1)) * wishart_log_det(a, B, detB, n_features))
 logprior += ((0.5 * a) * np.trace(B))
 return logprior

def _bound_wishart ( a , B , detB ) : n_features = B . shape [ 0 ] logprior = wishart_logz ( a , B , detB , n_features ) logprior -= wishart_logz ( n_features , np . identity ( n_features ) , 1 , n_features ) logprior += ( ( 0.5 * ( a - 1 ) ) * wishart_log_det ( a , B , detB , n_features ) ) logprior += ( ( 0.5 * a ) * np . trace ( B ) ) return logprior
returns a function of the dof .