slurm-gpu-training

Submit GPU training jobs to Slurm clusters with preflight validation and monitoring.

10|1|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/dongzhuoyao/tao-research-skills --skill slurm-gpu-training
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: slurm-gpu-training
Source: https://github.com/dongzhuoyao/tao-research-skills/tree/main/slurm-gpu-training
Command: npx skills add https://github.com/dongzhuoyao/tao-research-skills --skill slurm-gpu-training

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Running GPU-based machine learning workloads on Slurm-managed HPC clusters is error-prone and resource-expensive when jobs are misconfigured, dependencies are missing, or offline access is not handled; this Skill helps avoid wasted GPU hours by guiding submission, environment setup, monitoring, and failure triage.

Core Features & Use Cases

  • Preflight validation: Verify dataset caches, model weights, and environment variables before submitting a job.
  • Non-interactive environment init: Patterns for sourcing conda in batch shells and exporting LD_LIBRARY_PATH so CUDA libraries resolve properly.
  • Submission templates & monitoring: sbatch script conventions, job naming with SLURM_JOB_ID, walltime planning, and quick-use monitoring commands like squeue, sacct, and tail.
  • Failure triage & best practices: Detect OOMs, import errors, NaN losses, and implement offline-first workflows for package and model access.
  • Use case: Prepare and submit a fastrun smoke test that runs a short validation pass with cached datasets to catch config errors before a fullrun.

Quick Start

Submit a Slurm training job that runs a preflight check, activates conda in a non-interactive shell, enforces offline HF settings, and launches the sbatch template to start training.

Frequently Asked Questions about slurm-gpu-training

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I submit a PyTorch GPU training job to a Slurm cluster?▼

To submit a PyTorch GPU training job to a Slurm cluster, you use sbatch script conventions that allocate resources, activate conda non-interactively, and execute the training workflow with proper walltime planning.

How do I activate conda in a non-interactive Slurm batch shell?▼

To activate conda in a non-interactive Slurm batch shell, you must source the conda initialization script within your sbatch template and export LD_LIBRARY_PATH so CUDA libraries resolve properly before training.

Why does my Slurm GPU job fail with missing dataset or model weight errors?▼

Your Slurm GPU job fails with missing dataset or model weight errors because offline access is not handled; performing preflight validation to verify dataset caches and model weights prevents these import errors.

What is the best way to monitor a running Slurm GPU job and triage failures?▼

The best way to monitor a running Slurm GPU job and triage failures is using commands like squeue, sacct, and tail to check job status and detect OOMs, NaN losses, or import errors during post-mortem analysis.

Can I run a short smoke test on an HPC cluster before submitting a full GPU training job?▼

Yes, you can run a short smoke test on an HPC cluster before submitting a full GPU training job; this preflight check executes a brief validation pass with cached datasets to catch configuration errors early.

How do I configure offline Hugging Face settings for scheduled batch execution on Slurm?▼

To configure offline Hugging Face settings for scheduled batch execution on Slurm, you enforce offline environment variables in your sbatch template to ensure package and model access without internet connectivity.