运行简单语音识别代码示例时出错

时间:2019-07-19 13:30:04

标签: logging python-requests python-3.6 urllib3 pyttsx

我尝试了不同的方法,但无法摆脱这个问题

我正尝试通过访问此站点来创建简单的语音识别: https://www.codementor.io/edwardzionsaji/simple-voice-enabled-chat-bot-in-python-kt2qi5oke

我已经尝试过以下解决方案:PYTTSX Error: Cannot find module named drivers

并在错误下方找到了解决方法。

Traceback (most recent call last):
['hello', 'world', 'this', 'my', 'third', 'program']
  File "C:/Users/muhammed.khalifa/Desktop/program/speech_rec.py", line 5, in <module>
    import wikipedia
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\site-packages\wikipedia\__init__.py", line 1, in <module>
        from .wikipedia import *
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\site-packages\wikipedia\wikipedia.py", line 3, in <module>
        import requests
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\site-packages\requests\__init__.py", line 43, in <module>
        import urllib3
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\site-packages\urllib3\__init__.py", line 7, in <module>
        from .connectionpool import (
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\site-packages\urllib3\connectionpool.py", line 3, in <module>
        import logging
      File "C:\Users\muhammed.khalifa\AppData\Local\Programs\Python\Python36\lib\logging\__init__.py", line 28, in <module>
        from string import Template
    ImportError: cannot import name 'Template'

0 个答案:

没有答案