UMESH266 commited on
Commit
33ab516
·
1 Parent(s): 863b9e4

requirements updated

Browse files
Files changed (1) hide show
  1. src/utils/accessory.py +0 -12
src/utils/accessory.py CHANGED
@@ -6,7 +6,6 @@ import pygame
6
  from src.components.voicesynth import VoiceSynthesizer
7
  from src.logger.logger import logging
8
  from src.exception.exception import customexception
9
- import tkinter as tk
10
 
11
  # Initialize the voice recognizer
12
  r = sr.Recognizer()
@@ -47,19 +46,8 @@ def listen():
47
  print("Say something!")
48
  audio = r.listen(source)
49
 
50
- # # recognize speech using Sphinx
51
- # try:
52
- # print("Sphinx thinks you said " + r.recognize_sphinx(audio))
53
- # except sr.UnknownValueError:
54
- # print("Sphinx could not understand audio")
55
- # except sr.RequestError as e:
56
- # print("Sphinx error; {0}".format(e))
57
-
58
  # recognize speech using Google Speech Recognition
59
  try:
60
- # for testing purposes, we're just using the default API key
61
- # to use another API key, use `r.recognize_google(audio, key="GOOGLE_SPEECH_RECOGNITION_API_KEY")`
62
- # instead of `r.recognize_google(audio)`
63
  text = r.recognize_google(audio)
64
  print("Google Speech Recognition thinks you said " + text)
65
 
 
6
  from src.components.voicesynth import VoiceSynthesizer
7
  from src.logger.logger import logging
8
  from src.exception.exception import customexception
 
9
 
10
  # Initialize the voice recognizer
11
  r = sr.Recognizer()
 
46
  print("Say something!")
47
  audio = r.listen(source)
48
 
 
 
 
 
 
 
 
 
49
  # recognize speech using Google Speech Recognition
50
  try:
 
 
 
51
  text = r.recognize_google(audio)
52
  print("Google Speech Recognition thinks you said " + text)
53