SenseVoice icon indicating copy to clipboard operation
SenseVoice copied to clipboard

是否支持华为Ascend npu

Open lq0104 opened this issue 1 year ago • 12 comments

Notice: In order to resolve issues more efficiently, please raise issue following the template. (注意:为了更加高效率解决您遇到的问题,请按照模板提问,补充细节)

❓ Questions and Help

请问是否有支持华为Ascend npu的计划?

Before asking:

  1. search the issues.
  2. search the docs.

What is your question?

Code

What have you tried?

What's your environment?

  • OS (e.g., Linux):
  • FunASR Version (e.g., 1.0.0):
  • ModelScope Version (e.g., 1.11.0):
  • PyTorch Version (e.g., 2.0.0):
  • How you installed funasr (pip, source):
  • Python version:
  • GPU (e.g., V100M32)
  • CUDA/cuDNN version (e.g., cuda11.7):
  • Docker version (e.g., funasr-runtime-sdk-cpu-0.4.1)
  • Any other relevant information:

lq0104 avatar Aug 23 '24 02:08 lq0104

同问

YHSI5358 avatar Oct 31 '24 03:10 YHSI5358

同问

lai-serena avatar Jun 12 '25 07:06 lai-serena

同问

735726032 avatar Jul 09 '25 01:07 735726032

各位可以参考下我 fork 后的代码修改和文档:

  • https://github.com/yzztin/SenseVoice-npu
  • https://github.com/yzztin/SenseVoice-npu/blob/npu-support/README_npu.md

yzztin avatar Aug 11 '25 09:08 yzztin

各位可以参考下我 fork 后的代码修改和文档:

  • https://github.com/yzztin/SenseVoice-npu
  • https://github.com/yzztin/SenseVoice-npu/blob/npu-support/README_npu.md

不用torchAir的话,性能太差了

nayihz avatar Aug 13 '25 06:08 nayihz

不用torchAir的话,性能太差了

这里有官方适配的文档,供参考:

  • https://gitee.com/ascend/ModelZoo-PyTorch/blob/master/ACL_PyTorch/built-in/audio/SenseVoice/TorchAir/README.md
  • https://gitee.com/ascend/ModelZoo-PyTorch/blob/master/ACL_PyTorch/built-in/audio/SenseVoice/README_onnx.md

yzztin avatar Aug 13 '25 09:08 yzztin

对的,用官方torchAir的版本简单跑了一下性能测试,你的版本跟torchAir有几倍的性能差距

nayihz avatar Aug 14 '25 02:08 nayihz

请问官方版本可以直接在910B上运行推理吗

neoscheung avatar Sep 22 '25 15:09 neoscheung

可以关注 https://github.com/k2-fsa/sherpa-onnx/pull/2697

近期会支持 sense voice + Ascend 910B NPU.

paraformer 的支持更难,我们都搞定了. SenseVoice 更简单,所以肯定能支持。

csukuangfj avatar Oct 17 '25 16:10 csukuangfj

https://github.com/k2-fsa/sherpa-onnx/pull/2707

刚把 sense voice 导出到 ascend npu 910B.

csukuangfj avatar Oct 21 '25 10:10 csukuangfj

https://github.com/k2-fsa/sherpa-onnx/pull/2728

增加了 ACL C API 的例子。

Image

csukuangfj avatar Oct 27 '25 14:10 csukuangfj

已经更新文档

https://k2-fsa.github.io/sherpa/onnx/ascend/index.html

Image

csukuangfj avatar Oct 28 '25 04:10 csukuangfj