k2-fsa / sherpa-ncnn

Real-time speech recognition using next-gen Kaldi with ncnn without Internet connection. Support iOS, Android, Raspberry Pi, VisionFive2, LicheePi4A etc.
https://k2-fsa.github.io/sherpa/ncnn/index.html
Apache License 2.0
891 stars 138 forks source link

输入音频和视频文件转文字 #347

Closed jkm123 closed 4 days ago

jkm123 commented 4 days ago

是否支持传入一个音频和视频文件,输出文本;

csukuangfj commented 4 days ago

支持的,请用 https://github.com/k2-fsa/sherpa-ncnn/tree/master/ffmpeg-examples

jkm123 commented 4 days ago

怎么移植到Android端呢,有相关的demo不;

csukuangfj commented 4 days ago

https://github.com/k2-fsa/sherpa-ncnn/tree/master/android 这里有 demo.


https://github.com/k2-fsa/sherpa-ncnn/releases/tag/v2.1.10 这里有编译好的 apk, 你自己可以下载、测试。

jkm123 commented 4 days ago

感谢! 这个demo是实时语音识别的,我已了解; 我是想问输入:一个音频或视频文件,输出:文本,这种方式在Android端接入的文档或者demo有么;

csukuangfj commented 4 days ago

如何读音频文件,或者如何读视频文件,你自己解决,这个不是语音识别框架需要做的事情。

我们提供的 api, 不关注 audio samples 来自哪里。