| | |
| | | TCLAP::ValueArg<std::int32_t> audio_fs("", AUDIO_FS, "the sample rate of audio", false, 16000, "int32_t"); |
| | | TCLAP::ValueArg<std::int32_t> thread_num("", THREAD_NUM, "multi-thread num for rtf", true, 0, "int32_t"); |
| | | TCLAP::ValueArg<std::string> hotword("", HOTWORD, "the hotword file, one hotword perline, Format: Hotword Weight (could be: 阿里巴巴 20)", false, "", "string"); |
| | | TCLAP::SwitchArg use_gpu("", USE_GPU, "Whether to use GPU for inference, default is false", false); |
| | | TCLAP::SwitchArg use_gpu("", INFER_GPU, "Whether to use GPU for inference, default is false", false); |
| | | |
| | | cmd.add(model_dir); |
| | | cmd.add(quantize); |
| | |
| | | TCLAP::ValueArg<std::string> wav_path("", WAV_PATH, "the input could be: wav_path, e.g.: asr_example.wav; pcm_path, e.g.: asr_example.pcm; wav.scp, kaldi style wav list (wav_id \t wav_path)", true, "", "string"); |
| | | TCLAP::ValueArg<std::int32_t> audio_fs("", AUDIO_FS, "the sample rate of audio", false, 16000, "int32_t"); |
| | | TCLAP::ValueArg<std::string> hotword("", HOTWORD, "the hotword file, one hotword perline, Format: Hotword Weight (could be: 阿里巴巴 20)", false, "", "string"); |
| | | TCLAP::SwitchArg use_gpu("", USE_GPU, "Whether to use GPU for inference, default is false", false); |
| | | TCLAP::SwitchArg use_gpu("", INFER_GPU, "Whether to use GPU for inference, default is false", false); |
| | | |
| | | cmd.add(model_dir); |
| | | cmd.add(quantize); |
| | |
| | | #define MODEL_EB_NAME "model_eb.onnx" |
| | | #define QUANT_MODEL_NAME "model_quant.onnx" |
| | | // gpu models |
| | | #define USE_GPU "gpu" |
| | | #define INFER_GPU "gpu" |
| | | #define TORCH_MODEL_NAME "model.gpu.torchscripts" |
| | | #define TORCH_QUANT_MODEL_NAME "model.blade.fp16.pt" |
| | | |
| | |
| | | false, "/workspace/resources/hotwords.txt", "string"); |
| | | TCLAP::ValueArg<std::int32_t> fst_inc_wts("", FST_INC_WTS, |
| | | "the fst hotwords incremental bias", false, 20, "int32_t"); |
| | | TCLAP::SwitchArg use_gpu("", USE_GPU, "Whether to use GPU, default is false", false); |
| | | TCLAP::SwitchArg use_gpu("", INFER_GPU, "Whether to use GPU, default is false", false); |
| | | |
| | | // add file |
| | | cmd.add(hotword); |