本期小工具1:gpustat
安装方式:
pip install gpustat
常用指令:
watch -n 2 --color gpustat --c
可以实时查看所有GPU的配置及当前使用情况(含使用人),退出指令为ctrl+c
gpustat -i
本期小工具2:tmux
更全指令链接:https://zhuanlan.zhihu.com/p/102546608
常用指令:
tmux new -s test #创建名为test的会话(session)
ctrl+b d #退出tmux会话(ctrl+b后 松手 再d)
tmux a -t test #再次进入test
tmux ls #查看已有的tmux会话列表
tmux kill-session -t test #杀死名为test的会话
注:根据尝试,不可以把已经在终端运行的训练转移到tmux会话中。