当前位置: 首页 > news >正文

Linux conda activate报错:CondaError: Run ‘conda init‘ before ‘conda activate‘

Linux conda activate报错:CondaError: Run ‘conda init’ before ‘conda activate’

在Centos7.9的Linux系统环境下,64位,安装玩Conda,输入

conda activate testconda

报错,提示说运行conda activate前需要先运行conda init

[root@bigdata-server python]# conda activate testconda
Ignoring configuration file (/root/.condarc) due to error:
Unable to load configuration file.
path: /root/.condarc
reason: invalid yaml at line 44, column 0
Ignoring configuration file (/root/.condarc) due to error:
Unable to load configuration file.
path: /root/.condarc
reason: invalid yaml at line 44, column 0
Ignoring configuration file (/root/.condarc) due to error:
Unable to load configuration file.
path: /root/.condarc
reason: invalid yaml at line 44, column 0
Ignoring configuration file (/root/.condarc) due to error:
Unable to load configuration file.
path: /root/.condarc
reason: invalid yaml at line 44, column 0
CondaError: Run 'conda init' before 'conda activate'

但是输入conda init,却没有什么效果。

conda init

conda init完之后,conda activate testconda仍然报错:CondaError: Run ‘conda init’ before ‘conda activate’
【解决办法】
查找conda的环境路径

[root@bigdata-server python]# which conda
/root/anaconda3/bin/conda

添加codna的环境路径

vim ~/.bashrc

在最后一行添加

export CONDA_ENVS_PATH=~/anaconda3/envs

保存退出。

source ~/.bashrc

再输入conda activate testconda

conda activate testconda

正常。


http://www.mrgr.cn/news/55544.html

相关文章:

  • 设计模式——装饰者模式(8)
  • leetcode22.括号生成
  • 3.1.1ReactOS系统中搜索给定长度的空间地址区间函数的实现
  • 2024大模型应用实践报告|附35页PDF文件下载
  • 3分钟解决Ubuntu22.04没有声音输出设备
  • 爬虫python=豆瓣Top250电影
  • 算法|牛客网华为机试1-10C++
  • 拥抱云开发的未来:腾讯云数据库、云模板与AI智能化的应用场景探索
  • 大数据新视界 --大数据大厂之区块链技术:为大数据安全保驾护航
  • GEE引擎传奇UI界面修改教程
  • 【C Language】 运算符:按位运算符;逻辑运算符;关系运算符;条件运算符
  • 光伏工程造价单自动生成
  • CEEMDAN +组合预测模型(CNN-Transformer + ARIMA)
  • Markdown 简单实用的单词本格式编辑
  • Canal数据同步
  • 变换器交流模型建模方法
  • CCF-BDCI大数据与计算智能大赛TOP4-京东生鲜
  • 同济子豪兄--随机游走的艺术-图嵌入表示学习【斯坦福CS224W图机器学习】
  • 梦熊十三连测题解
  • 英语语法学习框架(考研)
  • STM32启动文件浅析
  • JavaScript 中的防抖和节流(简易版)
  • VSCode编译器改为中文
  • C语言中的内存函数
  • 没有网络限制!超简单本地部署 Llama3 的方法
  • MySQL-30.索引-介绍