class_docstr: CIDEr scorer.
class_docstr_tok: ["CIDEr","scorer","."]
docstr: Compute term frequency for reference data.
  This will be used to compute idf (inverse document frequency later)
  The term frequency is stored in the object
  :return: None
docstr_tok: ["Compute","term","frequency","for","reference","data",".","This","will","be","used","to","compute","idf","(","inverse","document","frequency","later",")","The","term","frequency","is","stored","in","the","object",":","return",":","None"]
code: def compute_doc_freq(self):
      """
      Compute term frequency for reference data.
      This will be used to compute idf (inverse document frequency later)
      The term frequency is stored in the object
      :return: None
      """
      for refs in self.crefs:
          # refs, k ref captions of one image
          for ngram in set(
              [ngram for ref in refs for (ngram, count) in ref.items()]
          ):  # noqa
              self.document_frequency[ngram] += 1
  
file_path: graph4nlp/graph4nlp/pytorch/modules/evaluation/cider_tool/cider_scorer.py
imports: import copy
  import math
  import os
  import sys
  from collections import defaultdict
  import numpy
label_desc: Use image node_id 6 for calling the CiderScorer obj's underlying member method code with example usage: obj.compute_doc_freq() without return types