should fix issue that arises when trying to prepare the dataset without slicing segments
This commit is contained in:
parent
0a5483e57a
commit
29290f574e
|
@ -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}"
|
||||
|
|
Loading…
Reference in New Issue
Block a user