Gregniuki commited on
Commit
69e0418
·
verified ·
1 Parent(s): dc754b4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -258,7 +258,7 @@ def infer_batch(ref_audio, ref_text, gen_text_batches, exp_name, remove_silence,
258
  gen_text_len = calculate_weighted_length(gen_text)
259
 
260
  # Duration calculation considering global speed factor
261
- duration = int(ref_audio_len / speed) + int(((ref_audio_len / ref_text_len) * gen_text_len) / speed)
262
 
263
  # Print the calculated duration
264
  print(f"Chunk {i + 1}: Duration: {duration} speed {speed}")
 
258
  gen_text_len = calculate_weighted_length(gen_text)
259
 
260
  # Duration calculation considering global speed factor
261
+ duration = int(ref_audio_len) + int(((ref_audio_len / ref_text_len) * gen_text_len) / speed)
262
 
263
  # Print the calculated duration
264
  print(f"Chunk {i + 1}: Duration: {duration} speed {speed}")