Make sure that you use the correct version of 'pip' installed for your Python interpreter

 

像matplotlib在pycharm安装时候报错Make sure that you use the correct version of 'pip' installed for your Python interpreter

就是在cmd进入下面的这个地址,然后运行

      python.exe -m pip install matplotlib

如果报错

pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
Collecting matplotlib
  Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/matplotlib/

此时需要换成国内源

           阿里云 http://mirrors.aliyun.com/pypi/simple/

            中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/ 

           豆瓣(douban) http://pypi.douban.com/simple/ 

           清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/

         中国科学技术大学 http://pypi.mirrors.ustc.edu.cn/simple/

 

再输入python.exe -m pip install matplotlib -i http://pypi.douban.com/simple --trusted-host pypi.douban.com

把红色的matplotlib替换成你要安装的库就可以了

 

Make sure that you use the correct version of 'pip' installed for your Python interpreter_第1张图片

Make sure that you use the correct version of 'pip' installed for your Python interpreter_第2张图片

你可能感兴趣的:(python)