YT_SRT_2 / app.py

Commit History

prompt="Transcribe the following audio file. if chinese, please using 'language: zh-TW' in the prompt.",
4712f49

youngtsai commited on

language="zh-TW"
06a37bc

youngtsai commited on

prompt="Transcribe the following audio file. if chinese, please using 'language: zh-TW' in the prompt."
47b9bfb

youngtsai commited on

transcription = json.dumps(transformed_data, indent=2, ensure_ascii=False)
386394a

youngtsai commited on

segments = srt_content.segments
2e45b5b

youngtsai commited on

segments = srt_content.segments
fdda9df

youngtsai commited on

transcription = json.dumps(segments, indent=2)
f4b67b4

youngtsai commited on

segments = srt_content["segments"]
e25ec78

youngtsai commited on

segments
cddbd83

youngtsai commited on

response_format="verbose_json",
cc06725

youngtsai commited on

response_format="json"
95c49e9

youngtsai commited on

codec_name = "mp3"
ee81d6a

youngtsai commited on

ydl.download([youtube_url])
dafc879

youngtsai commited on

'preferredcodec': 'opus',
f80841d

youngtsai commited on

def download_youtube_audio(youtube_url):
fd14cdc

youngtsai commited on

codec_name = "webm"
344e0ea

youngtsai commited on

response_format="vtt"
c37eb36

youngtsai commited on

nonsilent_ranges = detect_nonsilent(audio, min_silence_len=50, silence_thresh=-40)
0a54037

youngtsai commited on

def transcribe_audio_by_whisper(audio_path):
43a7a45

youngtsai commited on

import random
a46b138

youngtsai commited on

def process_youtube_video(password, url, method):
397e66b

youngtsai commited on

def download_youtube_audio(youtube_url):
503f089

youngtsai commited on

# from transformers import pipeline
3df00a0

youngtsai commited on

# from transformers import pipeline
ab2a083

youngtsai commited on

print("processing_time:", processing_time)
b952e72

youngtsai commited on

def transcribe_audio_by_whisper(audio_path):
3c30c75

youngtsai commited on

processing_time
f55852f

youngtsai commited on

transcribe_audio_by_transformers_pipeline
5137249

youngtsai commited on

print(f"Chunk {i+1}/{len(chunks)} transcribed")
28b9c77

youngtsai commited on

Textbox
986ef92

youngtsai commited on

gradio
3fedaba

youngtsai commited on