在 Anaconda 中用 pip 指令安装包时报错,需要升级 pip 来解决问题。在执行pip install --upgrade pip
后,报出如下错误:
ERROR: Could not install packages due to an EnvironmentError: [WinError 5] 拒绝访问。:‘d:\anaconda\envs\scripts\pip.exe’
Consider using the --user option or check the permissions.
python -m ensurepip
python -m pip install --upgrade pip