class_docstr: Generic trainer class for ESPnet training!
code: def train(self):
      # after collect_stats, define shape files
      self.train_config.train_shape_file = glob.glob(
          os.path.join(self.stats_dir, "train", "*shape")
      )
      self.train_config.valid_shape_file = glob.glob(
          os.path.join(self.stats_dir, "valid", "*shape")
      )
      assert (
          len(self.train_config.train_shape_file) > 0
          or len(self.train_config.valid_shape_file) > 0
      ), "You need to run collect_stats first."
  
      # finally start training.
      self.train_config.collect_stats = False
      self.train_config.output_dir = self.output_dir
      self.task_class.main(self.train_config)
  
imports: import glob
  import os
  from argparse import Namespace
  from espnetez.task import get_easy_task
label_desc: Use image node_id 2 for calling the Trainer obj's underlying member method code with example usage: obj.train() without return types