code: def main(sourcedir, filelistdir, savedir, dset, nj):
      """Prepare the Kaldi files.
  
      Args:
          sourcedir (str): LRS2 dataset dir.
          filelist (str): The dir of the mp4 file, it should be like
                          '5535415699068794046/00001'
          savedir (str): The dir save the Kaldi files.
          dset (str): Which set. For this code dset is pretrain set.
          nj (str): Number of multi processes.
  
      """
      nj = int(nj)
      if nj > 1:
          multicore = True
      else:
          multicore = False
      filelistdir = filelistdir + "/" + "Filelist_" + dset
      with open(filelistdir) as filelists:
          filelist = filelists.readlines()
      for i in range(len(filelist)):
          filelist[i] = filelist[i].strip("\n")
      if multicore is True:
          pool = mp.Pool(nj)
          job_args = [(i, dset, savedir, sourcedir) for i in filelist]
          pool.map(product_helper, job_args)
      else:
          for i in filelist:
              set(i, dset, savedir, sourcedir)
  
imports: import multiprocessing
  import os
  import sys
label_desc: Use image node_id 1 for calling a global function with example usage: main(sourcedir, filelistdir, savedir, dset, nj) without return types