def E_logqPi(self, LP):
    ''' Returns scalar value of E[ log q(PI)],
          calculated directly from local param dict LP
    '''
    alph = self.theta
    # logDirNormC : nDoc -len vector    
    logDirNormC = gammaln(alph.sum(axis=1)) - np.sum(gammaln(alph), axis=1)
    logDirPDF = np.sum((alph - 1.) * self.ElogTheta)
    return np.sum(logDirNormC) + logDirPDF
dataset/ETHPy150Open daeilkim/refinery/refinery/bnpy/bnpy-dev/bnpy/allocmodel/admix/HDPRelModel.py/HDPRelAssortModel.E_logqPi/original