class_docstr: Bleu Evaluator. Now, we support metrics `'bleu'`
      
class_docstr_tok: ["Bleu","Evaluator",".","Now",",","we","support","metrics","`","'bleu","'","`"]
code: def _generate_weights(self):
      self.ngram_weights = []
      for n in range(1, self.max_ngrams + 1):
          weights = [0.0] * self.max_ngrams
          weights[:n] = [1.0 / n] * n
          self.ngram_weights.append(weights)
  
file_path: TextBox/textbox/evaluator/bleu_evaluator.py
imports: import os
  import subprocess
  import nltk
  import tempfile
  import warnings
  import traceback
  from itertools import zip_longest
  from packaging import version
  from .abstract_evaluator import AbstractEvaluator
label_desc: Use image node_id 2 for calling the BleuEvaluator obj's underlying member method code with example usage: obj._generate_weights() without return types