FASR: Fast Automatic Speech Recognition
Project description
🪐 项目: fasr
Fast Auto Speech Recognition
📋 简介
fasr是一款快速且易于使用的python库,它源于FunASR,专注于推理性能,目标是成为一个工业级别的python语音识别推理库。
📋 安装
wpai
- 在wpai平台选择pytorch镜像后,执行以下命令安装所有依赖
bash install.sh
本地
fasr可以通过直接通过pip安装,但是如果需要使用gpu,需要安装pytorch和onnxruntime-gpu
pip install fasr
📋 使用
- 下载模型
fasr prepare
- 构建pipeline
from fasr import AudioPipeline
# 语音识别pipeline
asr = AudioPipeline().add_pipe('detector').add_pipe('recognizer').add_pipe('sentencizer')
# 准备音频数据url或者本地路径
urls = get_urls()
# 运行
audios = asr.run(urls)
# 打印结果
for audio in audios:
for channel in audio.channels:
print(channel.text)
📋 性能测试
双通道音频
vad->asr->punc
测试结果
cpu: Intel(R) Xeon(R) Silver 4210 CPU @ 2.20GHz (wpai cpu 2核)
gpu: rtx6000 (wpai vgpu 20)
| 框架 | 耗时 | 推理速度 | 加速比 |
|---|---|---|---|
| funasr | 368.8s | 46.34 | 1.0 |
| fasr | 153.92s | 111.03 | 2.4 |
vad
测试结果
cpu: Intel(R) Xeon(R) Silver 4210 CPU @ 2.20GHz (wpai cpu 2核)
gpu: rtx6000 (wpai vgpu 20)
| 框架 | 耗时 | 推理速度 | 加速比 |
|---|---|---|---|
| funasr | 219.8s | 77.75 | 1.0 |
| fasr | 86.32s | 197.98 | 2.55 |
单通道音频
pipeline
vad->asr->punc
测试结果
cpu: Intel(R) Xeon(R) Silver 4210 CPU @ 2.20GHz (wpai cpu 2核)
gpu: rtx6000 (wpai vgpu 20)
| 框架 | 耗时 | 推理速度 | 加速比 |
|---|---|---|---|
| funasr | 123.8s | 22.05 | 1.0 |
| fasr | 59.04s | 46.24 | 2.1 |
vad
测试结果
cpu: Intel(R) Xeon(R) Silver 4210 CPU @ 2.20GHz (wpai cpu 2核)
gpu: rtx6000 (wpai vgpu 20)
| 框架 | 耗时 | 推理速度 | 加速比 |
|---|---|---|---|
| funasr | 59.26s | 46.07 | 1.0 |
| fasr | 36.84s | 74.1 | 1.61 |
AISHELL
pipeline
vad->asr->punc
测试结果
cpu: Intel(R) Xeon(R) Silver 4210 CPU @ 2.20GHz (wpai cpu 2核)
gpu: rtx6000 (wpai vgpu 20)
| 框架 | 耗时 | 推理速度 | 加速比 |
|---|---|---|---|
| funasr | 123.8s | 18.65 | 1.0 |
| fasr | 59.04s | 32.71 | 1.8 |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fasr-0.1.7.tar.gz.
File metadata
- Download URL: fasr-0.1.7.tar.gz
- Upload date:
- Size: 3.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4349095813a4d06a945f079a4e57241f11343bcbf6dd7b074d1dbbd8cfdde129
|
|
| MD5 |
631217c27b673fedf89abd2679f9e2fd
|
|
| BLAKE2b-256 |
8a35592714b561eb562a9376321fcb529e022ca2d975d06eb8e67ac8f7132c71
|
File details
Details for the file fasr-0.1.7-py3-none-any.whl.
File metadata
- Download URL: fasr-0.1.7-py3-none-any.whl
- Upload date:
- Size: 3.3 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.5.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
193f3466f2e380e77c0db436ee2ff922d69ca8aa03952527e405fce36c92ad97
|
|
| MD5 |
5070d6ca11ef442f23cc9c3f6e57a71c
|
|
| BLAKE2b-256 |
990215fdd0cd78291b16a987b02cf1f4da0397971039fd79dfb4a638f18cb823
|