alphacep / alphacep/vosk-api

Run Vosk in a separate thread

Aperta
#1,285 9 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Jupyter Notebook
Stelle
15.1k
Fork
1.8k
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Excuse me,
I'm trying to construct a gui, so Vosk starts when pushing a button
Unfortunatly I'm not been able to run the recognition if I embbed all the code within a function, and call the function from a push button

I'm not findind the reason... the models loads, the queue is launched but it seems the data from the microphone is not stored
I've tried to addapt " https://github.com/alphacep/vosk-api/blob/master/python/example/test_microphone.py "and I think that the problem comes frome the while True loop, when <> is called, but I'm failing at maiking it work.

Is it possible to find this methods explained to try to go on?

with sd.RawInputStream(samplerate=args.samplerate, blocksize = 8000, device=args.device,
dtype="int16", channels=1, callback=callback) **_// I guess this is the method to store thought a callback the micro sounds._**

rec = KaldiRecognizer(model, args.samplerate) **_// I guess it is the class instance for the recognizer._**
data = q.get() **_// I Guess data is stored on the queue_**
rec.AcceptWaveform(data) **_// dont know_**
What is the difference between rec.PartialResult()) and rec.Result()?

Kind regards

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.