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)
- Looking for inbrowser speech aligner
- Python Demo Error HOT 7
- When will speaker identification functionality be supported in the C# version of sherpa-onnx?
- Error while clicking Generate on IOS-SwiftUI TTS HOT 9
- [Request] Nodejs ws offline example
- need b4a example HOT 1
- Generating speach in Russian with C# returns nonsence HOT 6
- VS2022 使用静态库编译MFC例程成功,使用动态库编译失败 HOT 10
- 使用 sherpa-onnx-streaming-zipformer-multi-zh-hans-2023-12-12 模型,热词异常 HOT 5
- TTS WebAssembly for other languages not work HOT 10
- sherpa-onnx-offline-tts: Allow piping text using cat or text file input with command line parameter HOT 1
- sherpa-onnx-offline-tts: Allow piping audio from tts directly to stdout for further processing
- tts: Increase TTS volume to 0 DB.
- Android TTS: Some ideas for packaging tts engine and voices/models
- TTS: Add a SAPI 5 driver for Windows HOT 2
- sherpa-onnx-keyword-spotter 使用命令行工具 识别结果找不到 HOT 1
- 麦克风采样率和通道数的设置问题 HOT 1
- Export Time Info. HOT 2
- 说话人识别繁体字问题 HOT 5
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.