def arg_max(self, verbose=1):
        
        max_log_prob = -np.inf
        maxima = []

        log_probs = self._log_probs()
        for (Z, log_prob) in log_probs:
            if log_prob == max_log_prob:
                maxima.append((Z, log_prob))
            elif log_prob > max_log_prob:
                max_log_prob = log_prob
                maxima = [(Z, log_prob)]

        self.arg_maxima = maxima
        self.Z = maxima[0][0]
        self._compute_top_doc()
        self._compute_word_top()
        self.inv_top_sums = 1. / self.word_top.sum(0)
        self.iteration = 1
        self.log_probs = [(1, max_log_prob)]

        if verbose > 0:
            print 'Number of maxima:', len(self.arg_maxima)
dataset/ETHPy150Open inpho/vsm/vsm/model/ldaexact.py/LdaExact.arg_max/original