should fix issue that arises when trying to prepare the dataset without slicing segments

remotes/1712616735600285754/tmp_refs/heads/master
mrq 2023-08-23 21:49:22 +07:00
parent 0a5483e57a
commit 29290f574e
1 changed files with 1 additions and 1 deletions

@ -2535,7 +2535,7 @@ def prepare_dataset( voice, use_segments=False, text_length=0, audio_length=0, p
duration = 0
for segment in result['segments']:
duration = max(duration, result['segments'][segment]['end'])
duration = max(duration, segment['end'])
if duration >= MAX_TRAINING_DURATION:
message = f"Audio too large, using segments: {filename}"