ckpt / code /hf_ckpt_sweeper.sbat
AE-W's picture
archive loose scripts/configs
219f052 verified
Raw
History Blame Contribute Delete
1.09 kB
#!/bin/bash
#SBATCH --job-name=hf_ckpt_sweeper
#SBATCH --mail-type=FAIL,END
#SBATCH --mail-user=dingqy@umich.edu
#SBATCH --nodes=1
#SBATCH --ntasks-per-node=1
# SA ckpts are ~18 GB and huggingface_hub buffers during upload — need
# enough RAM. Memory rule: always 11 GB/cpu; scale CPU to reach the target
# memory. 6 CPU × 11 GB = 66 GB total.
#SBATCH --cpus-per-task=6
#SBATCH --mem-per-cpu=11GB
#SBATCH --time=48:00:00
# CPU-only sweeper — uses lsa3 (not ahowens1) so it doesn't consume the AI
# lab's GPU allocation budget on a job that needs zero GPUs.
#SBATCH --account=lsa3
#SBATCH --partition=standard
#SBATCH --output=/nfs/turbo/coe-ahowens-nobackup/dingqy/hf_ckpt_sweeper-%j.log
#
# CPU-only background sweeper: uploads training ckpts to HF dataset
# AE-W/ckpt, then deletes the local copy. Keeps last.ckpt local so SLURM
# preemption / requeue can still resume. Run alongside the 4 training jobs.
#
set -eu
source /home/dingqy/.hf_token
PY=/nfs/turbo/coe-ahowens-nobackup/dingqy/miniforge3/envs/V2A/bin/python
"$PY" /nfs/turbo/coe-ahowens-nobackup/dingqy/hf_ckpt_sweeper.py