From f1d42c7776ab05e4c848d624b22aa6cc09b7d78a Mon Sep 17 00:00:00 2001 From: McCloudS <64094529+McCloudS@users.noreply.github.com> Date: Thu, 26 Oct 2023 09:23:00 -0600 Subject: [PATCH] Update subgen.py --- subgen/subgen.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/subgen/subgen.py b/subgen/subgen.py index 5772404..21a9da8 100644 --- a/subgen/subgen.py +++ b/subgen/subgen.py @@ -178,7 +178,7 @@ def gen_subtitles(video_file_path: str) -> None: try: print(f"Transcribing file: {video_file_path}") start_time = time.time() - result = model.transcribe_stable(video_file_path) + result = model.transcribe_stable(video_file_path, task="translate") result.to_srt_vtt(video_file_path.rsplit('.', 1)[0] + subextension, word_level=word_level_highlight) elapsed_time = time.time() - start_time minutes, seconds = divmod(int(elapsed_time), 60)