Views
No views yet
pip install faster-whisper1from faster_whisper import WhisperModel
2
3# Load the model
4model = WhisperModel("CWTchen/Belle-faster-whisper-large-v3-zh-punct", device="cuda", compute_type="float16")
5
6# Transcribe an audio file
7segments, info = model.transcribe("audio.mp3", language="zh")
8
9# Print the results
10for segment in segments:
11 print(f"[{segment.start:.2f}s -> {segment.end:.2f}s] {segment.text}")1segments, info = model.transcribe(
2 "audio.mp3",
3 language="zh",
4 beam_size=5,
5 vad_filter=True,
6 vad_parameters=dict(min_silence_duration_ms=500)
7)1ct2-transformers-converter \
2 --model BELLE-2/Belle-whisper-large-v3-zh-punct \
3 --output_dir Belle-faster-whisper-large-v3-zh-punct \
4 --copy_files tokenizer.json preprocessor_config.json \
5 --quantization float321@misc{belle-whisper-v3-zh,
2 author = {BELLE Team},
3 title = {Belle Whisper Large V3 Chinese Punctuation},
4 year = {2024},
5 publisher = {Hugging Face},
6 howpublished = {\url{[https://huggingface.co/BELLE-2/Belle-whisper-large-v3-zh-punct](https://huggingface.co/BELLE-2/Belle-whisper-large-v3-zh-punct)}}
7}