class_docstr: Base class for BLEU & NIST, providing tokenization and some basic n-gram matching
  functions.
docstr: Given a sentence, return n-grams of nodes for the given N. Lowercases
  everything if the measure should not be case-sensitive.
  @param n: n-gram 'N' (1 for unigrams, 2 for bigrams etc.)
  @param sent: the sent in question
  @return: n-grams of nodes, as tuples of tuples (t-lemma & formeme)
docstr_tok: ["Given","a","sentence",",","return","n-grams","of","nodes","for","the","given","N.","Lowercases","everything","if","the","measure","should","not","be","case-sensitive",".","@","param","n",":","n-gram","'N","'","(","1","for","unigrams",",","2","for","bigrams","etc",".",")","@","param","sent",":","the","sent","in","question","@","return",":","n-grams","of","nodes",",","as","tuples","of","tuples","(","t-lemma","&","formeme",")"]
code: def ngrams(self, n, sent):
      """Given a sentence, return n-grams of nodes for the given N. Lowercases
      everything if the measure should not be case-sensitive.
      @param n: n-gram 'N' (1 for unigrams, 2 for bigrams etc.)
      @param sent: the sent in question
      @return: n-grams of nodes, as tuples of tuples (t-lemma & formeme)
      """
      if not self.case_sensitive:
          return list(
              zip(
                  *[[tok.lower() for tok in sent[i:]] for i in range(n)]
              )
          )
      return list(zip(*[sent[i:] for i in range(n)]))
  
imports: from __future__ import unicode_literals
  from __future__ import division
  from builtins import zip
  from builtins import range
  from past.utils import old_div
  from builtins import object
  from collections import defaultdict
  import math
  import re
label_desc: Use image node_id 5 for calling the NGramScore obj's underlying member method code with example usage: obj.ngrams(n, sent) and returns: list, list