code: def read_train_file(zip_filename, filename, pipe):
      """
      Read and tokenize a train set
  
      All of the train data is inside one zip.  We read it one piece at a time
      """
      sentiment_data = []
      with zipfile.ZipFile(zip_filename) as zin:
          with zin.open(filename) as fin:
              for line_idx, line in enumerate(fin):
                  if isinstance(line, bytes):
                      line = line.decode("utf-8")
                  pieces = line.split(maxsplit=1)
                  if len(pieces) < 2:
                      continue
                  pieces = pieces[1].rsplit(maxsplit=1)
                  if len(pieces) < 2:
                      continue
                  text, label = pieces
                  try:
                      label = convert_label(label)
                  except ValueError:
                      raise ValueError(
                          "Unexpected train label %s at line %d\n%s"
                          % (label, line_idx, line)
                      )
                  sentiment_data.append(SentimentDatum(label, text))
  
      print(
          "Read %d texts from %s - %s"
          % (len(sentiment_data), zip_filename, filename)
      )
      sentiment_data = tokenize(sentiment_data, pipe)
      return sentiment_data
  
file_path: stanza/stanza/utils/datasets/sentiment/process_es_tass2020.py
imports: import os
  import zipfile
  import stanza
  from stanza.models.classifiers.data import SentimentDatum
  import stanza.utils.default_paths
  from stanza.utils.datasets.sentiment.process_utils import write_dataset, write_list
label_desc: Use image node_id 9 for calling a global function with example usage: read_train_file(zip_filename, filename, pipe) and returns: sentiment_data