class_docstr: This class holds data in kaldi-style directory.
class_docstr_tok: ["This","class","holds","data","in","kaldi-style","directory","."]
docstr: Load kaldi data directory.
docstr_tok: ["Load","kaldi","data","directory","."]
code: def __init__(self, data_dir):
      """Load kaldi data directory."""
      self.data_dir = data_dir
      self.segments = load_segments_rechash(
          os.path.join(self.data_dir, "segments")
      )
      self.utt2spk = load_utt2spk(
          os.path.join(self.data_dir, "utt2spk")
      )
      self.wavs = load_wav_scp(os.path.join(self.data_dir, "wav.scp"))
      self.reco2dur = load_reco2dur(
          os.path.join(self.data_dir, "reco2dur")
      )
      self.spk2utt = load_spk2utt(
          os.path.join(self.data_dir, "spk2utt")
      )
  
imports: from __future__ import print_function
  import io
  import os
  import subprocess
  import sys
  from functools import lru_cache
  import numpy
  import soundfile
label_desc: Use image node_id 1 to create a new KaldiData object  with example: obj = KaldiData(data_dir)