srun:执行作业
srun [-N] --gres=gpu:n 执行命令
如:srun --gres=gpu:2 python examples/ssd/ssd_pascal.py (使用服务器的2张GPU卡运行程序)
sbatch:提交批处理作业
需要些sh脚本,脚本范例如下:
#!/bin/bash
#file:test.sh
#set the number of nodes
#SBATCH --nodes=1
#set the number of tasks (processes) per node
#SBATCH --ntasks-per-node=1
#set partition
#SBATCH --partition=V100
#SBATCH --gres=gpu:2
#set max wallclock time
#SBATCH --time=2:00:00
#set name of job
#SBATCH --job-name=test
#set batch script's standard output
#SBATCH --output=test.out
#run the application
srun --gres=gpu:1 python examples/ssd/ssd_pascal.py
srun --gres=gpu:1 python examples/ssd/ssd_pascal1.py
scancel:取消作业
如:scancel 270(JOBID为270)
sinfo:查看节点与分区状态
squeue:查看队列状态