mirror of
https://github.com/ggerganov/whisper.cpp.git
synced 2024-12-18 20:27:53 +00:00
wchess : minor
This commit is contained in:
parent
ee65df7982
commit
4260d4fc70
@ -26,8 +26,8 @@ public:
|
||||
int32_t vad_ms = 2000;
|
||||
int32_t prompt_ms = 5000;
|
||||
int32_t command_ms = 4000;
|
||||
float vad_thold = 0.1f;
|
||||
float freq_thold = -1.0f;
|
||||
float vad_thold = 0.2f;
|
||||
float freq_thold = 100.0f;
|
||||
bool print_energy = false;
|
||||
};
|
||||
|
||||
|
@ -44,10 +44,15 @@ void get_audio(int ms, std::vector<float> & audio) {
|
||||
}
|
||||
|
||||
bool check_running() {
|
||||
g_pcmf32.clear();
|
||||
//g_pcmf32.clear();
|
||||
return g_running;
|
||||
}
|
||||
|
||||
bool clear_audio() {
|
||||
g_pcmf32.clear();
|
||||
return true;
|
||||
}
|
||||
|
||||
void wchess_main(size_t i) {
|
||||
struct whisper_full_params wparams = whisper_full_default_params(whisper_sampling_strategy::WHISPER_SAMPLING_GREEDY);
|
||||
|
||||
@ -81,6 +86,7 @@ void wchess_main(size_t i) {
|
||||
cb.check_running = check_running;
|
||||
cb.get_audio = get_audio;
|
||||
cb.set_moves = set_moves;
|
||||
cb.clear_audio = clear_audio;
|
||||
|
||||
WChess(g_contexts[i], wparams, cb, {}).run();
|
||||
if (i < g_contexts.size()) {
|
||||
|
Loading…
Reference in New Issue
Block a user