conda 常用命令, Non-zero exit code,You will need to adjust your conda configuration

简介: conda 常用命令, Non-zero exit code,You will need to adjust your conda configuration

报错:You will need to adjust your conda configuration to proceed.

Use conda config --show channels to view your configuration's current state,

and use conda config --show-sources to view config file locations.

报错: Non-zero exit code

报错:CondaHTTPError: HTTP 000 CONNECTION FAILED for url


等等,都是错,并且网上的回答很混乱,说清华镜像不能用个很多,自己搞不好就说镜像不行,真是的误导人。


清华镜像地址:anaconda | 镜像站使用帮助 | 清华大学开源软件镜像站 | Tsinghua Open Source Mirror;你进去看看,玩意地址更新了,你换上就是了。


先说几个conda命令:


升级


conda update conda
conda update anaconda
conda update anaconda-navigator    //update最新版本的anaconda-navigator

卸载


计算机控制面板->程序与应用->卸载        //windows
rm -rf anaconda    //ubuntu

最后,建议清理下.bashrc中的Anaconda路径。


conda环境使用基本命令:

conda update -n base conda        //update最新版本的conda
conda create -n xxxx python=3.5   //创建python3.5的xxxx虚拟环境
conda activate xxxx               //开启xxxx环境
conda deactivate                  //关闭环境
conda env list                    //显示所有的虚拟环境
conda config --show channels
conda config --show-sources

anaconda安装最新的TensorFlow版本


参考:已解决:用anaconda安装最新的TensorFlow版本_Mr番茄蛋的博客-CSDN博客


  1. 打开anaconda-prompt
  2. 查看tensorflow各个版本:(查看会发现有一大堆TensorFlow源,但是不能随便选,选择可以用查找命令定位)
anaconda search -t conda tensorflow
  1. 找到自己安装环境对应的最新TensorFlow后(可以在终端搜索anaconda,定位到那一行),然后查看指定包
anaconda show <USER/PACKAGE>
  1. 查看tensorflow版本信息
anaconda show anaconda/tensorflow
  1. 第4步会提供一个下载地址,使用下面命令就可安装1.8.0版本tensorflow


conda install --channel https://conda.anaconda.org/anaconda tensorflow=1.8.0

更新,卸载安装包:


conda list         #查看已经安装的文件包
conda update xxx   #更新xxx文件包
conda uninstall xxx   #卸载xxx文件包

删除虚拟环境


conda remove -n xxxx --all //创建xxxx虚拟环境

清理(conda瘦身)


conda clean就可以轻松搞定!第一步:通过conda clean -p来删除一些没用的包,这个命令会检查哪些包没有在包缓存中被硬依赖到其他地方,并删除它们。第二步:通过conda clean -t可以将conda保存下来的tar包。

conda clean -p      //删除没有用的包
conda clean -t      //tar打包


目录
相关文章
|
Linux Shell Python
-bash: pip: command not found pip命令报错 解决方法(Centos版)
-bash: pip: command not found pip命令报错 解决方法(Centos版)
3897 0
|
4月前
|
缓存 Python
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-npf9报错
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-npf9报错
|
6月前
|
安全 Python
【Python】 已解决:(pip提示)[notice] To update, run: python.exe -m pip install --upgrade pip
【Python】 已解决:(pip提示)[notice] To update, run: python.exe -m pip install --upgrade pip
353 0
【Python】 已解决:(pip提示)[notice] To update, run: python.exe -m pip install --upgrade pip
|
7月前
|
Shell Linux 开发工具
Anaconda安装后报错 -bash: conda: command not found 如何处理
【6月更文挑战第26天】Anaconda安装后报错 -bash: conda: command not found 如何处理
1632 4
|
6月前
|
Shell Linux 网络安全
【Python】已完美解决:(pip提示升级)WARNING: There was an error checking the latest version of pip.,
【Python】已完美解决:(pip提示升级)WARNING: There was an error checking the latest version of pip.,
782 0
|
6月前
|
Python
安装 supervisor报错执行python setup.py install时No local packages or working download links found for meld3
安装 supervisor报错执行python setup.py install时No local packages or working download links found for meld3
55 0
|
数据可视化 Python
常见的bug---5、在安装superset时候报错,Command “python setup.py egg_info“ failed with error code 1
常见的bug---5、在安装superset时候报错,Command “python setup.py egg_info“ failed with error code 1
|
Ubuntu
问题解决:Ubuntu安装ROS依赖出现ERROR: the following packages/stacks could not have their rosdep keys resolvedt
问题解决:Ubuntu安装ROS依赖出现ERROR: the following packages/stacks could not have their rosdep keys resolvedt
1680 0
|
Shell Linux C++
报错:CommandNotFoundError: Your shell has not been properly configured to use ‘conda activate‘. 问题解决
报错:CommandNotFoundError: Your shell has not been properly configured to use ‘conda activate‘. 问题解决
299 0
ubuntu16.04中ROS-Kinetic报错: not find a package configuration file provided by “gazebo_ros_control“
ubuntu16.04中ROS-Kinetic报错: not find a package configuration file provided by “gazebo_ros_control“
214 0