File size: 2,256 Bytes
15f2609 f3ecff1 1dd0b5c b0c7f00 1dd0b5c b0c7f00 1dd0b5c f3ecff1 6fe3508 f3ecff1 3478b67 f3ecff1 b0c7f00 f3ecff1 3478b67 f3ecff1 cfec603 3478b67 6fe3508 f3ecff1 15f2609 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 |
---
license: mit
language:
- en
pipeline_tag: automatic-speech-recognition
---
# sensevoice.axera
FunASR SenseVoice on Axera, official repo: https://github.com/FunAudioLLM/SenseVoice
## TODO
- [x] 支持AX630C
- [ ] 支持C++
- [x] 支持FastAPI
## 功能
- 语音识别
- 自动识别语言(支持中文、英文、粤语、日语、韩语)
- 情感识别
- 自动标点
- 支持流式识别
## 支持平台
- [x] AX650N
- [x] AX630C
## 环境安装
```
pip3 install -r requirements.txt
```
如果空间不足可以使用 --prefix 指定别的安装路径
## 使用
```
# 首次运行会自动从huggingface上下载模型, 保存到models中
python3 main.py -i 输入音频文件
```
运行参数说明:
| 参数名称 | 说明 | 默认值 |
| --- | --- | --- |
| --input/-i | 输入音频文件 | |
| --language/-l | 识别语言,支持auto, zh, en, yue, ja, ko | auto |
| --streaming | 流式识别 | |
### 示例:
example下有测试音频
如 粤语测试
```
python3 main.py -i example/yue.mp3
```
输出
```
RTF: 0.03026517820946964 Latency: 0.15689468383789062s Total length: 5.184s
['呢几个字。', '都表达唔到,我想讲嘅意。', '思。']
```
流式识别
```
python3 main.py -i example/zh.mp3 --streaming
```
输出
```
{'timestamps': [540], 'text': '开'}
{'timestamps': [540, 780, 1080], 'text': '开放时'}
{'timestamps': [540, 780, 1080, 1260, 1740], 'text': '开放时间早'}
{'timestamps': [540, 780, 1080, 1260, 1740, 1920, 2340], 'text': '开放时间早上9'}
{'timestamps': [540, 780, 1080, 1260, 1740, 1920, 2340, 2640], 'text': '开放时间早上9点'}
{'timestamps': [540, 780, 1080, 1260, 1740, 1920, 2340, 2640, 3060], 'text': '开放时间早上9点至'}
{'timestamps': [540, 780, 1080, 1260, 1740, 1920, 2340, 2640, 3060, 3780, 4020], 'text': '开放时间早上9点至下午'}
{'timestamps': [540, 780, 1080, 1260, 1740, 1920, 2340, 2640, 3060, 3780, 4020, 4440, 4620], 'text': '开放时间早上9点至下午五点'}
RTF: 0.03678379235444246
```
## 准确率
使用WER(Word-Error-Rate)作为评价标准
**WER = 0.0389**
### 复现测试结果
```
./download_datasets.sh
python test_wer.py -d datasets -l zh
```
## 技术讨论
- Github issues
- QQ 群: 139953715
|