code: def collect(f):
      path_to_wav = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "wav"
      )
      path_to_emotions = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "EmoEvaluation"
      )
      path_to_transcriptions = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "transcriptions"
      )
      path_to_mocap_hand = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "MOCAP_hand"
      )
      path_to_mocap_rot = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "MOCAP_rotated"
      )
      path_to_mocap_head = os.path.join(
          iemocap_path, path_map[f[0:5]], "dialog", "MOCAP_head"
      )
  
      mocap_f = f
      if f == "Ses05M_script01_1b":
          mocap_f = "Ses05M_script01_1"
  
      wav = get_audio(path_to_wav, f + ".wav")
      transcriptions = get_transcriptions(
          path_to_transcriptions, f + ".txt"
      )
      emotions = get_emotions(path_to_emotions, f + ".txt")
      sample = split_wav(wav, emotions)
  
      for ie, e in enumerate(emotions):
          """if 'F' in e['id']:
              e['signal'] = sample[ie]['left']
          else:
              e['signal'] = sample[ie]['right']"""
  
          e["signal"] = sample[ie]["left"]
          e.pop("left", None)
          e.pop("right", None)
          e["transcription"] = transcriptions[e["id"]]
          e["mocap_hand"] = get_mocap_hand(
              path_to_mocap_hand, mocap_f + ".txt", e["start"], e["end"]
          )
          e["mocap_rot"] = get_mocap_rot(
              path_to_mocap_rot, mocap_f + ".txt", e["start"], e["end"]
          )
          e["mocap_head"] = get_mocap_head(
              path_to_mocap_head, mocap_f + ".txt", e["start"], e["end"]
          )
          lock.acquire()
          if e["id"] not in ids:
              data.append(e)
              ids[e["id"]] = 1
          lock.release()
  
file_path: delta/egs/iemocap/emo/v1/local/python/mocap_data_collect.py
imports: import os
  import sys
  import tqdm
  import numpy
  import wave
  import copy
  import math
  import pickle
  from multiprocessing import Pool, Lock, cpu_count, Manager
  from sklearn.preprocessing import label_binarize
  from helper import *
label_desc: Use image node_id 4 for calling a global function with example usage: collect(f) without return types