HugoLaurencon commited on
Commit
2ebd35a
1 Parent(s): 3482b10

fix bug (wrong index for speaker_id)

Browse files
Files changed (1) hide show
  1. libri_light.py +1 -1
libri_light.py CHANGED
@@ -157,7 +157,7 @@ class LibriLight(datasets.GeneratorBasedBuilder):
157
  id_ = audio_file.replace(".flac", "")
158
  file = path if local_extracted_archive else audio_file
159
  audio = {"path": file, "bytes": f.read()}
160
- speaker_id = int(path_split[-2])
161
  path_json = path.replace(".flac", ".json")
162
  with open(path_json) as json_file:
163
  metadata = json.load(json_file)
 
157
  id_ = audio_file.replace(".flac", "")
158
  file = path if local_extracted_archive else audio_file
159
  audio = {"path": file, "bytes": f.read()}
160
+ speaker_id = int(path_split[-3])
161
  path_json = path.replace(".flac", ".json")
162
  with open(path_json) as json_file:
163
  metadata = json.load(json_file)