code: def get_ranks_from_mat(self, mat, label_append=" freq"):
      return pd.DataFrame(
          mat,
          index=pd.Series(
              self._corpus.get_terms(
                  use_metadata=self._use_non_text_features
              ),
              name="term",
          ),
          columns=[
              str(c) + label_append
              for c in self._corpus.get_categories()
          ],
      )
  
imports: import pandas
  from scattertext.termranking.TermRanker import TermRanker
label_desc: Use image node_id 2 for calling the OncePerDocFrequencyRanker obj's underlying member method code with example usage: obj.get_ranks_from_mat(mat, label_append) and returns: pd