code: def cook_refs(refs, n=4):  # lhuang: oracle will call with "average"
      """Takes a list of reference sentences for a single segment
      and returns an object that encapsulates everything that BLEU
      needs to know about them.
      :param refs: list of string : reference sentences for some image
      :param n: int : number of ngrams for which (ngram) representation is calculated
      :return: result (list of dict)
      """
      return [precook(ref, n) for ref in refs]
  
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 2 for calling a global function with example usage: cook_refs(refs, n) and returns: unknown