当前位置:网站首页>配置服务器环境
配置服务器环境
2022-07-26 18:10:00 【知道的都知道 不知道的慢慢了解】
vscode终端
user为自己的用户名
cd /home/503-2/
cp Anaconda3-2022.05-Linux-x86_64.sh /home/user
1.安装Anaconda
sh Anaconda3-2022.05-Linux-x86_64.sh
前面默认选择即可 一直enter
最后选择yes
在anaconda中安装
新建一个自己的python版本环境
conda create -n name python=3.8
name:你的环境名字,自定义
激活自己新建的环境
conda activate name
在自己的环境中安装torch
conda install pytorch torchvision torchaudio cudatoolkit=11.1 -c pytorch-lts -c nvidia
已测试可用
2.进入自己的文件夹里
cd home
ls
cd user
查看自己的环境
conda info -e
3.配置cuda
输入
vi .bashrc
添加
export PATH=/usr/local/cuda/bin${
PATH:+:${
PATH}}
export LD_LIBRARY_PATH=/usr/local/cuda/lib64${
LD_LIBRARY_PATH:+:${
LD_LIBRARY_PATH}}
3.关闭自己远程连接并重新连接
输入
nvcc -V
输出
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Sun_Mar_21_19:15:46_PDT_2021
Cuda compilation tools, release 11.3, V11.3.58
Build cuda_11.3.r11.3/compiler.29745058_0
成功!!!!
自己直接使用anaconda
4.【GPU】nvidia-smi
1.基础命令
nvidia-smi
安装完成后在命令行或终端输入命令nvidia-smi,即可看到下面的信息(点击放大):
表头释义:Fan:显示风扇转速,数值在0到100%之间,是计算机的期望转速,如果计算机不是通过风扇冷却或者风扇坏了,显示出来就是N/A;
Temp:显卡内部的温度,单位是摄氏度;
Perf:表征性能状态,从P0到P12,P0表示最大性能,P12表示状态最小性能;
Pwr:能耗表示;
Bus-Id:涉及GPU总线的相关信息;
Disp.A:是Display Active的意思,表示GPU的显示是否初始化;
Memory Usage:显存的使用率; 主要看这个
Volatile GPU-Util:浮动的GPU利用率;
Compute M:计算模式;
下边的Processes显示每块GPU上每个进程所使用的显存情况。
2.查看GPU是否空闲
nvidia-smi
3.查看进程的具体信息
ps aux|grep pid
查看pid号进程的具体信息,可以看到是哪个用户运行哪个程序
判断进程是不是死在里面了或者可以询问实验室的同学什么时候能跑完实验
4.杀进程:
kill -9 pid
5.查看conda版本python版本
conda --version
python
参考链接
这些链接都是精华 如果没看懂我的 看看这些链接 总有一款包您满意
在服务器上搭建自己的python环境(针对小白)
在linux服务器上配置虚拟环境–python+TensorFlow
深度学习实验基础02:实验室服务器使用
在实验室服务器上装anaconda环境并简单使用
如何在Linux服务器上安装Anaconda(超详细)
边栏推荐
- Usage scenarios for automated testing
- ReentrantLock学习之---基础方法
- ReentrantLock学习之---基本属性
- What aspects should be considered in the selection of MES system?
- 【MySQL必知必会】 日志Log详解
- LeetCode笔记:Weekly Contest 303
- 洋葱集团携手OceanBase实现分布式升级,全球数据首次实现跨云融合
- ReentrantLock学习之公平锁过程
- Racher deploys kubernetes cluster
- Network protocol: tcp/ip protocol
猜你喜欢

PMP每日一练 | 考试不迷路-7.26(包含敏捷+多选)

分布式事务-seata

篇7:exited on DESKTOP-DFF5KIK with error code -1073741511.

Sentinel isolation and degradation

Support proxy direct connection to Oracle database, jumpserver fortress v2.24.0 release

Comparison of advantages and disadvantages between SD NAND and EMMC

C#获取本地时间/系统时间

【Swoole系列3.1】进程、线程、协程,面试你被问了吗?

2022G1工业锅炉司炉上岗证题库及模拟考试

Introduce the difference between @getmapping and @postmapping in detail
随机推荐
Tensor RT's int8 quantization principle
JS刷题计划——数组
After the exam on June 25, see how the new exam outline reviews PMP
(ICLR-2022)TADA!用于视频理解的时间自适应卷积
一些时序建模策略(一)
Simulated 100 questions and simulated examination of refrigeration and air conditioning equipment operation examination in 2022
TB 117-2013美国联邦强制性法规
Leetcode simple question: the minimum total time required to fill a cup
MySQL log introduction
LeetCode-138-复制带随机指针的链表
Introduction to Seata
Vs2019 export import configuration
当前占位,之后再写
【Swoole系列3.1】进程、线程、协程,面试你被问了吗?
Advanced template (runner's notes)
PMP每日一练 | 考试不迷路-7.26(包含敏捷+多选)
立创EDA使用笔记
时空预测5-GAT
5 best overseas substitutes for WPS Office
ReentrantLock学习之---基础方法