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

AutoDL 云服务器:普通 用户 miniconda 配置

AutoDL 初始状态下只有root用户,miniconda 安装在root用户目录下

///

增加普通用户

root@autodl-container-1c0641804d-5bb7040c:~/Desktop# apt updateroot@autodl-container-1c0641804d-5bb7040c:~/Desktop#  apt install sudoroot@autodl-container-1c0641804d-5bb7040c:~/Desktop# adduser zhenglfroot@autodl-container-1c0641804d-5bb7040c:~/Desktop# usermod -aG sudo zhenglfroot@autodl-container-1c0641804d-5bb7040c:~/Desktop# su zhenglf

普通用户conda配置

zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ python
bash: python: command not found
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda
bash: conda: command not found
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ sudo /root/miniconda3/bin/conda init bash
no change     /root/miniconda3/condabin/conda
no change     /root/miniconda3/bin/conda
no change     /root/miniconda3/bin/conda-env
no change     /root/miniconda3/bin/activate
no change     /root/miniconda3/bin/deactivate
no change     /root/miniconda3/etc/profile.d/conda.sh
no change     /root/miniconda3/etc/fish/conf.d/conda.fish
no change     /root/miniconda3/shell/condabin/Conda.psm1
no change     /root/miniconda3/shell/condabin/conda-hook.ps1
no change     /root/miniconda3/lib/python3.8/site-packages/xontrib/conda.xsh
no change     /root/miniconda3/etc/profile.d/conda.csh
no change     /home/zhenglf/.bashrc
No action taken.
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ source  /home/zhenglf/.bashrc
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ cat  /home/zhenglf/.bashrc | grep conda
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/root/miniconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"eval "$__conda_setup"if [ -f "/root/miniconda3/etc/profile.d/conda.sh" ]; then. "/root/miniconda3/etc/profile.d/conda.sh"export PATH="/root/miniconda3/bin:$PATH"
unset __conda_setup
# <<< conda initialize <<<
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda
bash: conda: command not found
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ sudo chmod -R 777 /root
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda
usage: conda [-h] [-V] command ...conda is a tool for managing and deploying applications, environments and packages.Options:positional arguments:commandclean        Remove unused packages and caches.compare      Compare packages between conda environments.config       Modify configuration values in .condarc. This is modeled after the git config command. Writes to the user .condarc file (/home/zhenglf/.condarc) by default.create       Create a new conda environment from a list of specified packages.help         Displays a list of available conda commands and their help strings.info         Display information about current conda install.init         Initialize conda for shell interaction. [Experimental]install      Installs a list of packages into a specified conda environment.list         List linked packages in a conda environment.package      Low-level conda package utility. (EXPERIMENTAL)remove       Remove a list of packages from a specified conda environment.uninstall    Alias for conda remove.run          Run an executable in a conda environment. [Experimental]search       Search for packages and display associated information. The input is a MatchSpec, a query language for conda packages. See examples below.update       Updates conda packages to the latest compatible version.upgrade      Alias for conda update.optional arguments:-h, --help     Show this help message and exit.-V, --version  Show the conda version number and exit.conda commands available from other packages:env
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda env list
# conda environments:
#
base                  *  /root/miniconda3zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda activate baseCommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
To initialize your shell, run$ conda init <SHELL_NAME>Currently supported shells are:- bash- fish- tcsh- xonsh- zsh- powershellSee 'conda init --help' for more information and options.IMPORTANT: You may need to close and restart your shell after running 'conda init'.zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ source  /root/miniconda3/bin/activate
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda deactivate
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ conda activate base
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ which python
/root/miniconda3/bin/python
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$

(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$ history1  sudo /root/miniconda3/bin/conda init bash2  cat  /home/zhenglf/.bashrc3  python4  python35  source  /home/zhenglf/.bashrc6  python7  reset8  python9  conda10  sudo /root/miniconda3/bin/conda init bash11  cat  /home/zhenglf/.bashrc12  cat  /home/zhenglf/.bashrc | grep conda13  reset14  python15  conda16  sudo /root/miniconda3/bin/conda init bash17  source  /home/zhenglf/.bashrc18  cat  /home/zhenglf/.bashrc | grep conda19  conda20  sudo chmod -R 777 /root21  conda22  conda env list23  conda activate base24  source  /root/miniconda3/bin/activate25  conda deactivate26  conda activate base27  which python28  history
(base) zhenglf@autodl-container-b8974ea189-5aa9b74e:/root$

///

相关文章:

AutoDL 云服务器:普通 用户 miniconda 配置

AutoDL 初始状态下只有root用户&#xff0c;miniconda 安装在root用户目录下 /// 增加普通用户 rootautodl-container-1c0641804d-5bb7040c:~/Desktop# apt updaterootautodl-container-1c0641804d-5bb7040c:~/Desktop# apt install sudorootautodl-container-1c0641804d-5…...

渲染流程概述

渲染流程包括 CPU应用程序端渲染逻辑 和 GPU渲染管线 一、CPU应用程序端渲染逻辑 剔除操作对物体进行渲染排序打包数据调用Shader SetPassCall 和 Drawcall 1.剔除操作 视椎体剔除 &#xff08;给物体一个包围盒&#xff0c;利用包围盒和摄像机的视椎体进行碰撞检测&#xf…...

前端力扣刷题 | 4:hot100之 子串

560. 和为K的子数组 给你一个整数数组 nums 和一个整数 k &#xff0c;请你统计并返回 该数组中和为 k 的子数组的个数 。 子数组是数组中元素的连续非空序列。 示例&#xff1a; 输入&#xff1a;nums [1,1,1], k 2 输出&#xff1a;2 法一&#xff1a;暴力法 var subar…...

Julia 之 @btime 精准测量详解

Julia 语言因其高性能和易用性在科学计算、数据分析等领域获得了广泛关注。在性能优化中&#xff0c;精准测量代码执行时间是至关重要的任务&#xff0c;而 Julia 提供了强大的工具 btime 来辅助这一任务。本文将围绕 Julia 的 btime 来展开&#xff0c;帮助读者深入理解并高效…...

【Django教程】用户管理系统

Get Started With Django User Management 开始使用Django用户管理 By the end of this tutorial, you’ll understand that: 在本教程结束时&#xff0c;您将了解&#xff1a; Django’s user authentication is a built-in authentication system that comes with pre-conf…...

【机器学习】自定义数据集 使用pytorch框架实现逻辑回归并保存模型,然后保存模型后再加载模型进行预测

一、使用pytorch框架实现逻辑回归 1. 数据部分&#xff1a; 首先自定义了一个简单的数据集&#xff0c;特征 X 是 100 个随机样本&#xff0c;每个样本一个特征&#xff0c;目标值 y 基于线性关系并添加了噪声。将 numpy 数组转换为 PyTorch 张量&#xff0c;方便后续在模型中…...

C语言连接Mysql

目录 C语言连接Mysql下载 mysql 开发库 方法介绍mysql_init()mysql_real_connect()mysql_query()mysql_store_result()mysql_num_fields()mysql_fetch_fields()mysql_fetch_row()mysql_free_result()mysql_close() 完整代码 C语言连接Mysql 下载 mysql 开发库 方法一&#xf…...

Windows上通过Git Bash激活Anaconda

在Windows上配置完Anaconda后&#xff0c;普遍通过Anaconda Prompt激活虚拟环境并执行Python&#xff0c;如下图所示&#xff1a; 有时需要连续执行多个python脚本时&#xff0c;直接在Anaconda Prompt下可以通过在以下方式&#xff0c;即命令间通过&&连接&#xff0c;…...

面试经典150题——图

文章目录 1、岛屿数量1.1 题目链接1.2 题目描述1.3 解题代码1.4 解题思路 2、被围绕的区域2.1 题目链接2.2 题目描述2.3 解题代码2.4 解题思路 3、克隆图3.1 题目链接3.2 题目描述3.3 解题代码3.4 解题思路 4、除法求值4.1 题目链接4.2 题目描述4.3 解题代码4.4 解题思路 5、课…...

学习数据结构(1)时间复杂度

1.数据结构和算法 &#xff08;1&#xff09;数据结构是计算机存储、组织数据的方式&#xff0c;指相互之间存在⼀种或多种特定关系的数据元素的集合 &#xff08;2&#xff09;算法就是定义良好的计算过程&#xff0c;取一个或一组的值为输入&#xff0c;并产生出一个或一组…...

项目集成GateWay

文章目录 1.环境搭建1.创建sunrays-common-cloud-gateway-starter模块2.目录结构3.自动配置1.GateWayAutoConfiguration.java2.spring.factories 3.pom.xml4.注意&#xff1a;GateWay不能跟Web一起引入&#xff01; 1.环境搭建 1.创建sunrays-common-cloud-gateway-starter模块…...

【Ubuntu】使用远程桌面协议(RDP)在Windows上远程连接Ubuntu

使用远程桌面协议&#xff08;RDP&#xff09;在Windows上远程连接Ubuntu 远程桌面协议&#xff08;RDP&#xff09;是一种允许用户通过图形界面远程控制计算机的协议。本文将详细介绍如何在Ubuntu上安装和配置xrdp&#xff0c;并通过Windows的远程桌面连接工具访问Ubuntu。 …...

python3+TensorFlow 2.x 基础学习(一)

目录 TensorFlow 2.x基础 1、安装 TensorFlow 2.x 2、TensorFlow 2.x 基础概念 2、1 Eager Execution 2、2 TensorFlow 张量&#xff08;Tensor&#xff09; 3、使用Keras构建神经网络模型 3、1 构建 Sequential 模型 3、2 编译模型 1、Optimizer&#xff08;优化器&a…...

《活出人生的厚度》

《活出人生的厚度》可以从不同角度来理解和实践&#xff0c;以下为你提供一些拓展内容&#xff1a; ### 不断学习与自我提升 - **持续知识更新**&#xff1a;保持对新知识的渴望&#xff0c;利用各种渠道学习&#xff0c;如在线课程、学术讲座、行业研讨会等。例如&#xff0c…...

安装 docker 详解

在平常的开发工作中&#xff0c;我们经常需要部署项目。随着 Docker 容器的出现&#xff0c;大大提高了部署效率。Docker 容器包含了应用程序运行所需的所有依赖&#xff0c;避免了换环境运行问题。可以在短时间内创建、启动和停止容器&#xff0c;大大提高了应用的部署速度&am…...

【Rust自学】16.3. 共享状态的并发

喜欢的话别忘了点赞、收藏加关注哦&#xff08;加关注即可阅读全文&#xff09;&#xff0c;对接下来的教程有兴趣的可以关注专栏。谢谢喵&#xff01;(&#xff65;ω&#xff65;) 16.3.1. 使用共享来实现并发 还记得Go语言有一句名言是这么说的&#xff1a;Do not commun…...

开发者交流平台项目部署到阿里云服务器教程

本文使用PuTTY软件在本地Windows系统远程控制Linux服务器&#xff1b;其中&#xff0c;Windows系统为Windows 10专业版&#xff0c;Linux系统为CentOS 7.6 64位。 1.工具软件的准备 maven&#xff1a;https://archive.apache.org/dist/maven/maven-3/3.6.1/binaries/apache-m…...

【2024年华为OD机试】 (B卷,100分)- 乘坐保密电梯(JavaScriptJava PythonC/C++)

一、问题描述 问题描述 我们需要从0楼到达指定楼层m,乘坐电梯的规则如下: 给定一个数字序列,每次根据序列中的数字n,上升n层或下降n层。前后两次的方向必须相反,且首次方向向上。必须使用序列中的所有数字,不能只使用一部分。目标是到达指定楼层m,如果无法到达,则给出…...

maven的打包插件如何使用

默认的情况下&#xff0c;当直接执行maven项目的编译命令时&#xff0c;对于结果来说是不打第三方包的&#xff0c;只有一个单独的代码jar&#xff0c;想要打一个包含其他资源的完整包就需要用到maven编译插件&#xff0c;使用时分以下几种情况 第一种&#xff1a;当只是想单纯…...

solidity高阶 -- 线性继承

Solidity是一种面向合约的高级编程语言&#xff0c;用于编写智能合约。在Solidity中&#xff0c;多线继承是一个强大的特性&#xff0c;允许合约从多个父合约继承属性和方法。本文将详细介绍Solidity中的多线继承&#xff0c;并通过不同的实例展示其使用方法和注意事项。 在Sol…...

零门槛NAS搭建:WinNAS如何让普通电脑秒变私有云?

一、核心优势&#xff1a;专为Windows用户设计的极简NAS WinNAS由深圳耘想存储科技开发&#xff0c;是一款收费低廉但功能全面的Windows NAS工具&#xff0c;主打“无学习成本部署” 。与其他NAS软件相比&#xff0c;其优势在于&#xff1a; 无需硬件改造&#xff1a;将任意W…...

大话软工笔记—需求分析概述

需求分析&#xff0c;就是要对需求调研收集到的资料信息逐个地进行拆分、研究&#xff0c;从大量的不确定“需求”中确定出哪些需求最终要转换为确定的“功能需求”。 需求分析的作用非常重要&#xff0c;后续设计的依据主要来自于需求分析的成果&#xff0c;包括: 项目的目的…...

1688商品列表API与其他数据源的对接思路

将1688商品列表API与其他数据源对接时&#xff0c;需结合业务场景设计数据流转链路&#xff0c;重点关注数据格式兼容性、接口调用频率控制及数据一致性维护。以下是具体对接思路及关键技术点&#xff1a; 一、核心对接场景与目标 商品数据同步 场景&#xff1a;将1688商品信息…...

连锁超市冷库节能解决方案:如何实现超市降本增效

在连锁超市冷库运营中&#xff0c;高能耗、设备损耗快、人工管理低效等问题长期困扰企业。御控冷库节能解决方案通过智能控制化霜、按需化霜、实时监控、故障诊断、自动预警、远程控制开关六大核心技术&#xff0c;实现年省电费15%-60%&#xff0c;且不改动原有装备、安装快捷、…...

el-switch文字内置

el-switch文字内置 效果 vue <div style"color:#ffffff;font-size:14px;float:left;margin-bottom:5px;margin-right:5px;">自动加载</div> <el-switch v-model"value" active-color"#3E99FB" inactive-color"#DCDFE6"…...

OPenCV CUDA模块图像处理-----对图像执行 均值漂移滤波(Mean Shift Filtering)函数meanShiftFiltering()

操作系统&#xff1a;ubuntu22.04 OpenCV版本&#xff1a;OpenCV4.9 IDE:Visual Studio Code 编程语言&#xff1a;C11 算法描述 在 GPU 上对图像执行 均值漂移滤波&#xff08;Mean Shift Filtering&#xff09;&#xff0c;用于图像分割或平滑处理。 该函数将输入图像中的…...

A2A JS SDK 完整教程:快速入门指南

目录 什么是 A2A JS SDK?A2A JS 安装与设置A2A JS 核心概念创建你的第一个 A2A JS 代理A2A JS 服务端开发A2A JS 客户端使用A2A JS 高级特性A2A JS 最佳实践A2A JS 故障排除 什么是 A2A JS SDK? A2A JS SDK 是一个专为 JavaScript/TypeScript 开发者设计的强大库&#xff…...

华为OD机试-最短木板长度-二分法(A卷,100分)

此题是一个最大化最小值的典型例题&#xff0c; 因为搜索范围是有界的&#xff0c;上界最大木板长度补充的全部木料长度&#xff0c;下界最小木板长度&#xff1b; 即left0,right10^6; 我们可以设置一个候选值x(mid)&#xff0c;将木板的长度全部都补充到x&#xff0c;如果成功…...

深入浅出Diffusion模型:从原理到实践的全方位教程

I. 引言&#xff1a;生成式AI的黎明 – Diffusion模型是什么&#xff1f; 近年来&#xff0c;生成式人工智能&#xff08;Generative AI&#xff09;领域取得了爆炸性的进展&#xff0c;模型能够根据简单的文本提示创作出逼真的图像、连贯的文本&#xff0c;乃至更多令人惊叹的…...

nnUNet V2修改网络——暴力替换网络为UNet++

更换前,要用nnUNet V2跑通所用数据集,证明nnUNet V2、数据集、运行环境等没有问题 阅读nnU-Net V2 的 U-Net结构,初步了解要修改的网络,知己知彼,修改起来才能游刃有余。 U-Net存在两个局限,一是网络的最佳深度因应用场景而异,这取决于任务的难度和可用于训练的标注数…...