程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

How to resolve the failure of installing wordcloud library with PIP in python3.9

編輯:Python

Catalog

Preface

Problems arise

Problem solving process

1. Manual download and installation whl file

2. Input pip install wheel

3. Enter the path where the file is located , Then enter... Under the file path pip install < The file name downloaded in the first step >

summary

Preface

The process is sad , Tried all kinds of methods , The last discovery may be in cmd The following code file path is not correct ?:

pip install wordcloud‑1.8.1‑cp39‑cp39‑win_amd64.whl

Okay , I don't say much nonsense , Let's talk in detail about our sad journey

Problems arise

stay cmd Input in pip install wordcloud

A full screen of red error messages appears , Go online for help , It is found that such error reports are frequently mentioned :

error: Microsoft Visual C++ 14.0 is required. Get it with “Microsoft Visual C++ Build Tools”: https://visualstudio.microsoft.com/visual-cpp-build-tools/

I also found this error message in the middle of the red screen , So follow the answer to a series of operations …

Problem solving process 1. Manual download and installation whl file

Download address :https://www.lfd.uci.edu/~gohlke/pythonlibs/#wordcloud

Here, please choose according to your own software version

I'm using Python3.9 windows System is 64, The choice is :

2. Input pip install wheel

Up to this point , According to my answers on the Internet, they are all successful

Enter and return , Will show :

Requirement already satisfied:wheel in d: program files (x86)python\lib\site-packages

3. Enter the path where the file is located , Then enter... Under the file path pip install < The file name downloaded in the first step >

notes : During the specific input process, you should < The file name downloaded in the first step > Replace with the name of the file you downloaded ~~

C:\Users\15654>cd D:\Program Files (x86)\Python\DLLsC:\Users\15654>d:D:\Program Files (x86)\Python\DLLs>pip install wordcloud-1.8.1-cp39-cp39-win_amd64.whl

We don't know how to download and install the files wordcloud-1.8.1-cp39-cp39-win_amd64.whl Under that path , You can go through it first " File search " Function search wordcloud-1.8.1-cp39-cp39-win_amd64.whl, Then right-click to choose “ Where to open the file ”, Copy the file path after entering .

My file path is D:\Program Files (x86)\Python\DLLs

therefore , In the first column of code, I enter :

cd D:\Program Files (x86)\Python\DLLs

The above steps are particularly important !!! Be sure to find the right file path !!!

Find the right path and enter pip install … You can install it successfully ~

Here are the less relevant ones :

It is because in this step, I put 2 In step wheel The path is taken as wordcloud-1.8.1-cp39-cp39-win_amd64.whl File path

In path D:\Program Files (x86)\Python Input directly pip install wordcloud-1.8.1-cp39-cp39-win_amd64.whl

An error is as follows :

WTARNING: Requirement 'wordcloud-1.8.1-cp39-cp39-win_amd64.whl’looks like a filename, but the file does not exist
ERROR: wordcloud-1.8.1-cp39-cp39-win_amd64.whl is not a valid wheel filename.

Friends who encounter this situation like me can find their own file path , So as not to take many detours like me , Download again Microsoft Visual C++ 14.0, According to the situation of other respondents , Hard copy of raw materials pip install matplotlib,pip install kiwisover

In the end, it still can't be solved , I want to see if I have successfully installed this file , So I searched this file , It turns out that the previous path is wrong .

And then it was cmd Change the path to D:\Program Files (x86)\Python\DLLs Enter pip install wordcloud-1.8.1-cp39-cp39-win_amd64.whl Show :Successfully installed wordcloud-1.8.1

wordcloud Installation succeeded ~~

summary

This is about Python3.9 use pip install wordcloud This is the end of the article on how to solve library failures , More about Python3.9 pip install wordcloud Please search the previous articles of the software development network or continue to browse the relevant articles below. I hope you can support the software development network in the future !



  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved