mirror of
https://github.com/SevaSk/ecoute.git
synced 2024-12-19 20:57:53 +00:00
Fixed closing UI not ending threads
This commit is contained in:
parent
178fc26d94
commit
392235ec29
2
main.py
2
main.py
@ -78,12 +78,14 @@ def main():
|
|||||||
|
|
||||||
global_transcriber = AudioTranscriber(user_audio_recorder.source, speaker_audio_recorder.source)
|
global_transcriber = AudioTranscriber(user_audio_recorder.source, speaker_audio_recorder.source)
|
||||||
transcribe = threading.Thread(target=global_transcriber.transcribe_audio_queue, args=(audio_queue,))
|
transcribe = threading.Thread(target=global_transcriber.transcribe_audio_queue, args=(audio_queue,))
|
||||||
|
transcribe.daemon = True
|
||||||
transcribe.start()
|
transcribe.start()
|
||||||
|
|
||||||
print(f"[INFO] Whisper using GPU: " + str(torch.cuda.is_available()))
|
print(f"[INFO] Whisper using GPU: " + str(torch.cuda.is_available()))
|
||||||
|
|
||||||
responder = GPTResponder()
|
responder = GPTResponder()
|
||||||
respond = threading.Thread(target=responder.respond_to_transcriber, args=(global_transcriber,))
|
respond = threading.Thread(target=responder.respond_to_transcriber, args=(global_transcriber,))
|
||||||
|
respond.daemon = True
|
||||||
respond.start()
|
respond.start()
|
||||||
|
|
||||||
print("READY")
|
print("READY")
|
||||||
|
Loading…
Reference in New Issue
Block a user