🚀 Whisper Large V3(泰语):组合版本V1
本模型是基于 openai/whisper-medium 在增强版的 mozilla-foundation/common_voice_13_0 泰语数据集、google/fleurs 数据集以及精心挑选的数据集上进行微调得到的。它在 common-voice-13 测试集上取得了以下成绩:
- 字错率(WER):6.59(使用 Deepcut 分词器)
🚀 快速开始
使用 Hugging Face 的 transformers
库调用该模型的示例代码如下:
from transformers import pipeline
MODEL_NAME = "biodatlab/whisper-th-large-v3-combined"
lang = "th"
device = 0 if torch.cuda.is_available() else "cpu"
pipe = pipeline(
task="automatic-speech-recognition",
model=MODEL_NAME,
chunk_length_s=30,
device=device,
)
pipe.model.config.forced_decoder_ids = pipe.tokenizer.get_decoder_prompt_ids(
language=lang,
task="transcribe"
)
text = pipe("audio.mp3")["text"]
💻 使用示例
基础用法
from transformers import pipeline
MODEL_NAME = "biodatlab/whisper-th-large-v3-combined"
lang = "th"
device = 0 if torch.cuda.is_available() else "cpu"
pipe = pipeline(
task="automatic-speech-recognition",
model=MODEL_NAME,
chunk_length_s=30,
device=device,
)
pipe.model.config.forced_decoder_ids = pipe.tokenizer.get_decoder_prompt_ids(
language=lang,
task="transcribe"
)
text = pipe("audio.mp3")["text"]
📚 详细文档
模型描述
该模型是 openai/whisper-medium 的微调版本,在增强版的 mozilla-foundation/common_voice_13_0 泰语数据集、google/fleurs 数据集以及精心挑选的数据集上进行训练。在 common-voice-13 测试集上,其字错率(WER)为 6.59(使用 Deepcut 分词器)。
预期用途与限制
更多信息待补充。
训练和评估数据
更多信息待补充。
训练过程
训练超参数
训练过程中使用了以下超参数:
属性 |
详情 |
学习率 |
1e-05 |
训练批次大小 |
16 |
评估批次大小 |
16 |
随机种子 |
42 |
优化器 |
AdamW(β1 = 0.9,β2 = 0.999,ε = 1e-08) |
学习率调度器类型 |
线性 |
学习率调度器热身步数 |
500 |
训练步数 |
10000 |
混合精度训练 |
原生自动混合精度(Native AMP) |
框架版本
- Transformers 4.37.2
- Pytorch 2.1.0
- Datasets 2.16.1
- Tokenizers 0.15.1
引用
使用 BibTeX 引用该模型:
@misc {thonburian_whisper_med,
author = { Atirut Boribalburephan, Zaw Htet Aung, Knot Pipatsrisawat, Titipat Achakulvisut },
title = { Thonburian Whisper: A fine-tuned Whisper model for Thai automatic speech recognition },
year = 2022,
url = { https://huggingface.co/biodatlab/whisper-th-medium-combined },
doi = { 10.57967/hf/0226 },
publisher = { Hugging Face }
}
📄 许可证
本模型采用 Apache-2.0 许可证。