class_docstr: A data structure to represent a parse tree
class_docstr_tok: ["A","data","structure","to","represent","a","parse","tree"]
docstr: Get the labels of the leaves
docstr_tok: ["Get","the","labels","of","the","leaves"]
code: def leaf_labels(self):
      """
      Get the labels of the leaves
      """
      if self.is_leaf():
          return [self.label]
  
      words = [x.children[0].label for x in self.yield_preterminals()]
      return words
  
imports: from collections import deque, Counter
  from enum import Enum
  from io import StringIO
  import itertools
  import re
  import warnings
  from stanza.models.common.stanza_object import StanzaObject
label_desc: Use image node_id 5 for calling the Tree obj's underlying member method code with example usage: obj.leaf_labels() and returns: words, list