Comments (17)
Have you tested your exported model in icefall?
Can you check that --context-size is the same in training and exporting?
from sherpa-onnx.
Have you tested your exported model in icefall?
How can I test my exported model in icefall ?
By now I only used decode.py script from icefall CV recipe to get WER.
Can you check that --context-size is the same in training and exporting?
I checked and --context-size is the same in training and exporting, it has a default value of 2.
from sherpa-onnx.
By now I only used decode.py script from icefall CV recipe to get WER.
Have you tried modified beam search with decode.py ?
Please post the commands you use for training, decoding, and exporting.
from sherpa-onnx.
Have you tried modified beam search with decode.py ?
Yes, I used --decoding-method modified_beam_search
with decode.py.
Please post the commands you use for training, decoding, and exporting.
Training:
python3 scripts/train.py --world-size 8 --num-epochs 100 --start-epoch 1 --use-fp16 true --max-duration 550 --enable-musan true --use-validated-set true --bpe-model $data_dir/lang_bpe_500/bpe.model --manifest-dir $data_dir/fbank --exp-dir $base_dir
Decoding:
python3 scripts/decode.py --epoch 100 --avg 1 --max-duration 550 --decode-chunk-len 32 --decoding-method modified_beam_search --use-averaged-model false --bpe-model $lang_dir/bpe.model --lang-dir $lang_dir --manifest-dir $data_dir/fbank --exp-dir $base_dir
Exporting:
python3 scripts/export-onnx.py --epoch 100 --avg 1 --use-averaged-model false --tokens $data_dir/lang_bpe_500/tokens.txt --exp-dir $base_dir
from sherpa-onnx.
What is scripts
? Which model are you using?
What changes have you made to icefall?
from sherpa-onnx.
scripts
is my local folder which contains all the files from the newest icefall Common Voice streaming zipformer transducer recipe from:
https://github.com/k2-fsa/icefall/tree/master/egs/commonvoice/ASR/pruned_transducer_stateless7_streaming
Only change I made to icefall is adding MLS and VoxPopuli datasets to the CV preparation script prepare.sh
, which is from:
https://github.com/k2-fsa/icefall/blob/master/egs/commonvoice/ASR/prepare.sh
MLS is in https://github.com/k2-fsa/icefall/tree/master/egs/librispeech/ASR
VoxPopuli is in https://github.com/k2-fsa/icefall/tree/master/egs/voxpopuli/ASR
from sherpa-onnx.
Could you test your model with
https://github.com/k2-fsa/icefall/blob/master/egs/commonvoice/ASR/pruned_transducer_stateless7_streaming/onnx_pretrained.py
and
https://github.com/k2-fsa/icefall/blob/master/egs/commonvoice/ASR/pruned_transducer_stateless7_streaming/jit_trace_pretrained.py
and see if it works.
from sherpa-onnx.
Could you test your model with
https://github.com/k2-fsa/icefall/blob/master/egs/commonvoice/ASR/pruned_transducer_stateless7_streaming/onnx_pretrained.py
I tested, works perfectly, recognized text exactly matches original one.
I tested, works perfectly too and recognized text exactly matches original one.
from sherpa-onnx.
Have you tried modified beam search with decode.py ?
Yes, I used
--decoding-method modified_beam_search
with decode.py.Please post the commands you use for training, decoding, and exporting.
Training:
python3 scripts/train.py --world-size 8 --num-epochs 100 --start-epoch 1 --use-fp16 true --max-duration 550 --enable-musan true --use-validated-set true --bpe-model $data_dir/lang_bpe_500/bpe.model --manifest-dir $data_dir/fbank --exp-dir $base_dir
Decoding:
python3 scripts/decode.py --epoch 100 --avg 1 --max-duration 550 --decode-chunk-len 32 --decoding-method modified_beam_search --use-averaged-model false --bpe-model $lang_dir/bpe.model --lang-dir $lang_dir --manifest-dir $data_dir/fbank --exp-dir $base_dir
Exporting:
python3 scripts/export-onnx.py --epoch 100 --avg 1 --use-averaged-model false --tokens $data_dir/lang_bpe_500/tokens.txt --exp-dir $base_dir
Could you also share the logs for the above 3 commands?
(You can find them from the terminal output. Please post the first few lines of them where configuration arguments can be found.)
from sherpa-onnx.
Could you also share the logs for the above 3 commands?
(You can find them from the terminal output. Please post the first few lines of them where configuration arguments can be found.)
Logs:
train_log.txt
decode_log.txt
export-onnx_log.txt
It was made on --world-size 8
so I give only cuda:0
.
Also --num-epochs
in train.py
is 50
, and --epoch
in decode.py
and export-onnx.py
is also 50
, not 100
as I posted before, because I noticed that I trained two times: from epoch 1 to 50 and then from 51 to 100.
from sherpa-onnx.
By the way, are you using the latest icefall and latest sherpa-onnx ?
from sherpa-onnx.
Yes, I used docker image (torch2.2.2-cuda12.1) with icefall and after training I tested it with sherpa-onnx built from latest GitHub source.
from sherpa-onnx.
@csukuangfj Hello! Could You help me with this issue ? I shared the logs as You asked in the post before. Thanks in advance.
from sherpa-onnx.
I don't see anything abnormal in your logs.
Sorry that I have no idea why greedy search works but modified_beam_search does not.
(Could you share your model files so that we can reproduce it and debug it locally?)
from sherpa-onnx.
I don't see anything abnormal in your logs.
Sorry that I have no idea why greedy search works but modified_beam_search does not.
Aha, I see, it's great that logs are OK.
Could you share your model files so that we can reproduce it and debug it locally?
Which model files should I share ? Do you mean exported encoder, decoder and joiner with .onnx extension and tokens.txt ?
from sherpa-onnx.
Do you mean exported encoder, decoder and joiner with .onnx extension and tokens.txt ?
Yes. Please also share a test wave file.
from sherpa-onnx.
Could you share your model files so that we can reproduce it and debug it locally?
Please also share a test wave file.
Please see my shared folder with model and test wave files: link here
from sherpa-onnx.
Related Issues (20)
- 在做ASR时,如果对麦克风收音做降噪处理? HOT 1
- TTS,除了命令行调用外,能否在Python里直接调用?想避免模型重复加载耗时 HOT 4
- [Help wanted] Add OnlineNeMoCtcModelConfig to C API
- [Help wanted] Flutter APP for text-to-speech
- 把SherpaOnnx 样例的Android kotlin代码转成Java就无法识别声音 HOT 3
- 如何调节输出音频的音量 HOT 1
- The command line tool named 'sherpa-onnx-cli' for convert the original keywords to tokens HOT 2
- Keyword spotting:iOS的keywords模型有吗 HOT 1
- Could you upload the apk of the latest update HOT 6
- swift api 中的hotwords,等同kotlin里的keywords吗 HOT 2
- I'm searching for the sherpa app in which the user can load a gguf model locally and chat with it using text messages HOT 1
- ImportError: ../../../_deps/onnxruntime-src/lib/libonnxruntime_providers_cuda.so: cannot open shared object file: No such file or directory HOT 53
- 发型的paraformer 2pass apk包,这个paraformer是large模型吗 HOT 2
- win x64 使用paraformer模型的问题 HOT 6
- Runtime option to disable sherpa logs HOT 2
- Import Piper / VITS as iOS Custom System Voices for TTS using AVSpeechSynthesisProviderAudioUnit Extension in Swift HOT 1
- Convert new piper tts models. HOT 1
- Multi-language support issue with Sherpa ONNX conversion (on android device)
- Use offline model to stream online HOT 1
- Errors and Questions regarding exporting a model HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sherpa-onnx.