code: def check_for_required_files(feat_dir, tree_dir, lat_dir=None):
      files = [
          "{0}/feats.scp".format(feat_dir),
          "{0}/ali.1.gz".format(tree_dir),
          "{0}/final.mdl".format(tree_dir),
          "{0}/tree".format(tree_dir),
      ]
      if lat_dir is not None:
          files += [
              "{0}/lat.1.gz".format(lat_dir),
              "{0}/final.mdl".format(lat_dir),
              "{0}/num_jobs".format(lat_dir),
          ]
      for file in files:
          if not os.path.isfile(file):
              raise Exception("Expected {0} to exist.".format(file))
  
file_path: espnet/egs2/must_c_v2/asr1/steps/libs/nnet3/train/chain_objf/acoustic_model.py
imports: from __future__ import division
  from __future__ import print_function
  import logging
  import math
  import os
  import sys
  import libs.common
  import libs.nnet3.train.common
label_desc: Use image node_id 6 for calling a global function with example usage: check_for_required_files(feat_dir, tree_dir, lat_dir) without return types