(self)
Figures out most attributes of the tier object:
        class, name, xmin, xmax, transcript.
Figures out most attributes of the tier object:
        class, name, xmin, xmax, transcript.
Figures out most attributes of the tier object : class name xmin xmax transcript .
def _make_info(self):
    """
        Figures out most attributes of the tier object:
        class, name, xmin, xmax, transcript.
        """

    trans = "([\S\s]*)"
    if self.text_type == "ChronTextFile":
      classid = "\"(.*)\" +"
      nameid = "\"(.*)\" +"
      xmin = "(\d+\.?\d*) +"
      xmax = "(\d+\.?\d*) *[\r\n]+"
      # No size values are given in the Chronological Text File format.
      self.size = None
      size = ""
    elif self.text_type == "ooTextFile":
      classid = " +class = \"(.*)\" *[\r\n]+"
      nameid = " +name = \"(.*)\" *[\r\n]+"
      xmin = " +xmin = (\d+\.?\d*) *[\r\n]+"
      xmax = " +xmax = (\d+\.?\d*) *[\r\n]+"
      size = " +\S+: size = (\d+) *[\r\n]+"
    elif self.text_type == "OldooTextFile":
      classid = "\"(.*)\" *[\r\n]+"
      nameid = "\"(.*)\" *[\r\n]+"
      xmin = "(\d+\.?\d*) *[\r\n]+"
      xmax = "(\d+\.?\d*) *[\r\n]+"
      size = "(\d+) *[\r\n]+"
    m = re.compile(classid + nameid + xmin + xmax + size + trans)
    self.tier_info = m.findall(self.tier)[0]
    self.classid = self.tier_info[0]
    self.nameid = self.tier_info[1]
    self.xmin = float(self.tier_info[2])
    self.xmax = float(self.tier_info[3])
    if self.size != None:
      self.size = int(self.tier_info[4])
    self.transcript = self.tier_info[-1]
def _make_info ( self ) : trans = "([\S\s]*)" if self . text_type == "ChronTextFile" : classid = "\"(.*)\" +" nameid = "\"(.*)\" +" xmin = "(\d+\.?\d*) +" xmax = "(\d+\.?\d*) *[\r\n]+" # No size values are given in the Chronological Text File format. self . size = None size = "" elif self . text_type == "ooTextFile" : classid = " +class = \"(.*)\" *[\r\n]+" nameid = " +name = \"(.*)\" *[\r\n]+" xmin = " +xmin = (\d+\.?\d*) *[\r\n]+" xmax = " +xmax = (\d+\.?\d*) *[\r\n]+" size = " +\S+: size = (\d+) *[\r\n]+" elif self . text_type == "OldooTextFile" : classid = "\"(.*)\" *[\r\n]+" nameid = "\"(.*)\" *[\r\n]+" xmin = "(\d+\.?\d*) *[\r\n]+" xmax = "(\d+\.?\d*) *[\r\n]+" size = "(\d+) *[\r\n]+" m = re . compile ( classid + nameid + xmin + xmax + size + trans ) self . tier_info = m . findall ( self . tier ) [ 0 ] self . classid = self . tier_info [ 0 ] self . nameid = self . tier_info [ 1 ] self . xmin = float ( self . tier_info [ 2 ] ) self . xmax = float ( self . tier_info [ 3 ] ) if self . size != None : self . size = int ( self . tier_info [ 4 ] ) self . transcript = self . tier_info [ - 1 ]