Skip to content

Commit

Permalink
Fixup. Format code with Black
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions committed Jul 1, 2024
1 parent f47939c commit 6350758
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions pod/video_encode_transcript/transcript_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ def main_whisper_transcript(norm_mp3_file, duration, lang):
"download_root"
],
)
'''
"""
for start_trim in range(0, duration, TRANSCRIPTION_AUDIO_SPLIT_TIME):
log.info("start_trim: " + str(start_trim))
audio = convert_samplerate(
Expand All @@ -436,13 +436,8 @@ def main_whisper_transcript(norm_mp3_file, duration, lang):
segment["text"],
)
webvtt.captions.append(caption)
'''
audio = convert_samplerate(
norm_mp3_file,
desired_sample_rate,
0,
duration
)
"""
audio = convert_samplerate(norm_mp3_file, desired_sample_rate, 0, duration)
transcription = model.transcribe(audio, language=lang)
for segment in transcription["segments"]:
caption = Caption(
Expand Down

0 comments on commit 6350758

Please sign in to comment.