class_docstr: WSDSample Class
class_docstr_tok: ["WSDSample","Class"]
docstr: Get lemma for list of words.
  :param words: a list of words,e.g.['he',['pointed','out']]
  :return: lemma_sent: lemma for list of words
docstr_tok: ["Get","lemma","for","list","of","words",".",":","param","words",":","a","list","of","words",",","e.g",".","[","'he","'",",","[","'pointed","'",",","'out","'","]","]",":","return",":","lemma_sent",":","lemma","for","list","of","words"]
code: def get_lemma(self, words):
      r"""
      Get lemma for list of words.
      :param words: a list of words,e.g.['he',['pointed','out']]
      :return: lemma_sent: lemma for list of words
      """
      from nltk.stem import WordNetLemmatizer
  
      wnl = WordNetLemmatizer()
      lemma_sent = []
      # get corresponding pos tag according to wordnet
      pos = self.tag_words(words, wn=True)
      for word, tag in zip(words, pos):
          if isinstance(word, str):
              if isinstance(tag, str):
                  lemma_sent.append(wnl.lemmatize(word, tag))
              else:
                  lemma_sent.append(word)  # None type
          elif isinstance(word, list):
              assert isinstance(tag, list), "invalid format of tag"
              assert len(word) == len(tag), "inconsistent tagging"
              lemma = []
              for w, t in zip(word, tag):
                  assert isinstance(w, str), "invalid format of word"
                  if isinstance(t, str):
                      lemma.append(wnl.lemmatize(w, t))
                  else:
                      lemma.append(w)
              lemma_sent.append(lemma)
      return lemma_sent
  
imports: from .sample import Sample
  from ..field import TextField, ListField
  import json
  from ....common.settings import TASK_MASK, PUNC
  import nltk
label_desc: Use image node_id 10 for calling the WSDSample obj's underlying member method code with example usage: obj.get_lemma(words) and returns: lemma_sent