🚀 Monsoon-Whisper-Medium-Gigaspeech2
Monsoon-Whisper-Medium-Gigaspeech2 是一個🇹🇭 泰語 自動語音識別(ASR)模型。它基於 Whisper-Medium 構建,並在 GigaSpeech2 上進行了微調。
該模型最初是作為自動語音識別任務中湧現能力研究的規模實驗而開發的。它在實際應用中表現出色,包括處理來自 YouTube 的音頻以及在嘈雜環境中的音頻。
更多詳細信息可在我們的 Typhoon-Audio 發佈博客 中找到。
🚀 快速開始
本部分將為你介紹如何快速使用 Monsoon-Whisper-Medium-Gigaspeech2 模型進行泰語自動語音識別。
✨ 主要特性
- 基於 Whisper-Medium 架構,在 GigaSpeech2 數據集上微調,適用於泰語自動語音識別。
- 最初作為研究自動語音識別任務中湧現能力的規模實驗開發。
- 在實際應用中表現出色,能處理來自 YouTube 的音頻和嘈雜環境中的音頻。
📦 安裝指南
- 要求:transformers 4.38.0 或更高版本。
💻 使用示例
基礎用法
from transformers import WhisperProcessor, WhisperForConditionalGeneration
import torchaudio
import torch
model_path = "scb10x/monsoon-whisper-medium-gigaspeech2"
device = "cuda"
filepath = 'audio.wav'
processor = WhisperProcessor.from_pretrained(model_path)
model = WhisperForConditionalGeneration.from_pretrained(
model_path, torch_dtype=torch.bfloat16
)
model.to(device)
model.eval()
model.config.forced_decoder_ids = processor.get_decoder_prompt_ids(
language="th", task="transcribe"
)
array, sr = torchaudio.load(filepath)
input_features = (
processor(array, sampling_rate=sr, return_tensors="pt")
.to(device)
.to(torch.bfloat16)
.input_features
)
predicted_ids = model.generate(input_features)
transcription = processor.batch_decode(predicted_ids, skip_special_tokens=True)
print(transcription)
📚 詳細文檔
模型描述
屬性 |
詳情 |
模型類型 |
Whisper Medium |
要求 |
transformers 4.38.0 或更高版本 |
主要語言 |
泰語 🇹🇭 |
許可證 |
Apache 2.0 |
評估結果
模型 |
WER (GS2) |
WER (CV17) |
CER (GS2) |
CER (CV17) |
whisper-large-v3 |
37.02 |
22.63 |
24.03 |
8.49 |
whisper-medium |
55.64 |
43.01 |
37.55 |
16.41 |
biodatlab-whisper-th-medium-combined |
31.00 |
14.25 |
21.20 |
5.69 |
biodatlab-whisper-th-large-v3-combined |
29.02 |
15.72 |
19.96 |
6.32 |
monsoon-whisper-medium-gigaspeech2 |
22.74 |
20.79 |
14.15 |
6.92 |
預期用途與限制
本模型為實驗性模型,可能並非始終準確。開發者應在具體應用場景中仔細評估潛在風險。
關注我們與支持
- https://twitter.com/opentyphoon
- https://discord.gg/us5gAYmrxw
颱風團隊
Kunat Pipatanakul、Potsawee Manakul、Sittipong Sripaisarnmongkol、Natapong Nitarach、Warit Sirichotedumrong、Adisai Na-Thalang、Phatrasek Jirabovonvisut、Parinthapat Pengpun、Krisanapong Jirayoot、Pathomporn Chokchainant、Kasima Tharnpipitchai
📄 許可證
本模型採用 Apache 2.0 許可證。