首先安装pip
检测方法就是在cmd中直接输入 pip
然后运行命令
C:\Users\Administrator>pip install PIL --allow-external PIL --allow-unverified PIL
如果报错如下:
error: Microsoft Visual C++ 9.0 is required (Unable to find vcvarsall.bat). Get
it from http://aka.ms/vcpython27
就去 下载:http://aka.ms/vcpython27
安装完成以后再运行:pip install PIL --allow-external PIL --allow-unverified PIL
最后就OK了
以后再需要什么库直接使用pip安装就行了:
pip install PyYaml
PyYaml 是你需要的库的名字,你可以根据需要改变