docstr: Different from traditional TF-IDF calculation, original authors treat handle single token is separately.
  Even though they are same, they will calculate TF-IDF separately. Possible reason is that they want
  to guarantee random behavior independently.
docstr_tok: ["Different","from","traditional","TF-IDF","calculation",",","original","authors","treat","handle","single","token","is","separately",".","Even","though","they","are","same",",","they","will","calculate","TF-IDF","separately",".","Possible","reason","is","that","they","want","to","guarantee","random","behavior","independently","."]
code: def cal_tfidf(self, word_idxes, tokens, normalize=True):
      """
      Different from traditional TF-IDF calculation, original authors treat handle single token is separately.
      Even though they are same, they will calculate TF-IDF separately. Possible reason is that they want
      to guarantee random behavior independently.
      """
      tfidf = []
      for idx in word_idxes:
          token = tokens[idx]
          tfidf.append(self.w2idf[token] / len(tokens))
  
      tfidf = np.array(tfidf)
  
      if normalize:
          return self._normalize(tfidf)
  
      return tfidf
  
file_path: nlpaug/nlpaug/model/word_stats/tfidf.py
imports: import os
  import math
  import numpy
  from nlpaug.model.word_stats import WordStatistics
label_desc: Use image node_id 3 for calling the TfIdf obj's underlying member method code with example usage: obj.cal_tfidf(word_idxes, tokens, normalize) and returns: tfidf, self