sbatch作用详解:掌握Slurm调度内存检查与GPU资源验证技巧
!/bin/bash
SBATCH --job-name=data_clean
SBATCH --output=clean.log
python data_preprocessing.py
!/bin/bash
AVAIL_MEM=$(sinfo -p ${PARTITION} -h -o "%m") if [ $REQUEST_MEM -gt $AVAIL_MEM ]; then
echo "错误:请求内存超过分区最大值 ${AVAIL_MEM}MB"
fi
scontrol show node ${NODE} | grep Gres=gpu