Home > Operation and Maintenance > Linux Operation and Maintenance > How to solve the connection timeout when using pip to install SpeechRecognition under Linux

How to solve the connection timeout when using pip to install SpeechRecognition under Linux

王林
Release: 2023-05-24 16:19:17
forward
1161 people have browsed it

Use pip to install SpeechRecognition under Linux

You will often see statements like import speechrecognition as sr in the code. To check the relevant information, you need to use pip to install SpeechRecognition. . First install pip under Linux, and then install it through the command pip install SpeechRecognition. There will always be a large section of red text (roughly meaning network timeout when connecting to a third-party library). The content of the red text is roughly as follows:

How to solve the connection timeout when using pip to install SpeechRecognition under Linux

I checked a lot of information online, and some said it was a change. Just change the capitalization of the letters and then restore them to the previous ones. I tested it and it didn’t work! ! !
After searching for a long time, I finally found the solution! ! ! !
Solution:
pip specifies the installation source for installation: pip install -i https://pypi.tuna.tsinghua.edu.cn/simple SpeechRecognition
Effective in actual testing:

How to solve the connection timeout when using pip to install SpeechRecognition under Linux

The above is the detailed content of How to solve the connection timeout when using pip to install SpeechRecognition under Linux. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:yisu.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template