BrunoHays commited on
Commit
e2b318f
·
1 Parent(s): de78f7c

Update ESLO.py

Browse files
Files changed (1) hide show
  1. ESLO.py +2 -1
ESLO.py CHANGED
@@ -382,6 +382,7 @@ class ESLO(datasets.GeneratorBasedBuilder):
382
  utterances = iter(utterances)
383
  if self.config.single_samples:
384
  yield from utterances
 
385
  merged_utterance = next(utterances)
386
  start_time = merged_utterance.start_timestamp
387
  while True:
@@ -389,7 +390,7 @@ class ESLO(datasets.GeneratorBasedBuilder):
389
  new_utterance = next(utterances)
390
  except StopIteration:
391
  yield merged_utterance
392
- break
393
  end_time = new_utterance.end_timestamp
394
  if end_time - start_time > self.config.max_duration:
395
  yield merged_utterance
 
382
  utterances = iter(utterances)
383
  if self.config.single_samples:
384
  yield from utterances
385
+ return
386
  merged_utterance = next(utterances)
387
  start_time = merged_utterance.start_timestamp
388
  while True:
 
390
  new_utterance = next(utterances)
391
  except StopIteration:
392
  yield merged_utterance
393
+ return
394
  end_time = new_utterance.end_timestamp
395
  if end_time - start_time > self.config.max_duration:
396
  yield merged_utterance