SkillsReviewed · wshobson

Spark Training Gotchas

Spark Training Gotchas is an assistant skill for developers training models on NVIDIA DGX Spark, but its automated checks cover only part of its troubleshooting advice. It pairs ten named issues with diagnostic commands for CUDA compatibility, shared memory, cooling, attention backends, precision and two-machine training. Its performance figures and workarounds are documentation claims; runtime behavior was not tested.

Researched 17 Nov 2026

In short.

Spark Training Gotchas is a troubleshooting skill for developers running model training on NVIDIA DGX Spark, but its preflight script cannot establish that a training job is ready to run. The folder combines ten numbered diagnostic topics, a Bash script covering five of them and a detailed command reference. Several checks require manual interpretation, and the script does not verify kernel compilation targets or sustained thermal behavior. The documentation also includes disruptive operations: clearing the system-wide page cache and running a memory-intensive bandwidth check. No commands were executed, and the reported compatibility observations and performance figures were not independently verified.

Researched and written by an AI model and checked by a second AI model. How it works

Coverage includes exactly plugins/dgx-spark-ops/skills/spark-training-gotchas/SKILL.md, assets/preflight.sh and references/gotcha-checks.md at revision 9c61ab243def98f72da12abd41cfcf5bcd91af9d, plus the repository-root LICENSE as the related notice outside the folder. Other skills, external packages, container images and upstream issue contents are excluded. The pinned folder address preserves access to the original files and their relative paths. No code was executed; runtime behavior, compatibility, training outcomes and performance remain unverified.

The overview

identity

Spark Training Gotchas is the spark-training-gotchas skill in the wshobson/agents repository, under plugins/dgx-spark-ops/skills/spark-training-gotchas. It contains SKILL.md, assets/preflight.sh and references/gotcha-checks.md.

The skill supplies instructions and diagnostic commands for an assistant or developer to follow. Its stable G1–G10 identifiers connect symptoms, explanations and checks across the three files.

assessment

The resource is useful as a focused troubleshooting reference for training failures, unexpected memory exhaustion and declining throughput on DGX Spark. Its detailed reference adds important qualifications to the short symptom table, including when capped workloads can coexist and when an attention-backend workaround applies.

The documentation reports approximately 100 W sustained power, 180–192 GB/s memory bandwidth and an approximately 32% NVFP4 slowdown relative to FP8 without the relevant compilation target. No underlying measurements or sufficient benchmark conditions are supplied to establish these as general hardware limits. The blanket recommendation against tensor parallelism across two Sparks likewise lacks supporting networking results here.

users

The intended users are developers fine-tuning models on DGX Spark and operators sharing its memory between training and inference services. Relevant situations include failed imports, out-of-memory errors, long-running jobs, attention-backend selection and planning a two-Spark training setup.

Beginners get a symptom-to-check structure, but using the remedies requires familiarity with Linux terminals, Python environments, PyTorch and containers. Experienced developers get implementation details such as an Unsloth loader workaround, CUDA runtime checks and distinctions between GPU capability and kernel compilation targets.

capabilities

The ten topics cover CUDA build/runtime mismatch, flash-attn and Unsloth backend selection, unified-memory exhaustion, thermal throttling, bandwidth limits, competing GPU workloads, FP8 versus NVFP4, stale vendor playbooks, Python dependency drift and parallelism across two Sparks.

The preflight script covers G1, G3, G4, G7 and G9. The reference supplies additional checks for attention packages, resident processes, upstream issues and training configuration. It also documents a separate bandwidth experiment. The script performs observations and prints results; it contains no automatic repair commands.

Using it

requirements

The documented target is DGX Spark's GB10 platform: aarch64, SM121 and 128 GB of unified memory shared by CPU and GPU. The guide expects a PyTorch build reporting CUDA 13.x.

The script uses Bash, Python 3, PyTorch, nvidia-smi, free, awk, sed, grep and Linux container markers or procfs information. Complete GPU readings require a working CUDA environment. Most diagnostic commands need no root privileges; clearing the page cache does. The upstream-issue command requires an authenticated gh CLI, with a browser visit offered as an alternative.

A particular assistant host, model provider or automatic skill installation mechanism is not specified.

mechanism

G1 reads torch.version.cuda and prints PASS when the value starts with 13. G3 prints free and used memory from free -g. G4 takes one temperature and power snapshot. G7 checks whether PyTorch reports device capability (12, 1). G9 looks for Docker, Podman or cgroup container markers.

These results have different meanings. G3 and G4 are raw readings, and G7 confirms hardware capability without checking whether kernels target sm_121a. G9 returns UNKNOWN when no container marker matches, because missing markers do not establish that the process is running directly on the host. The detailed reference adds runtime-library checks and sustained thermal sampling.

setup

Obtain the complete skill folder at the documented revision, preserving its assets and references directories: [https://github.com/wshobson/agents/tree/9c61ab243def98f72da12abd41cfcf5bcd91af9d/plugins/dgx-spark-ops/skills/spark-training-gotchas]. Retain the repository MIT notice with redistributed copies.

From the skill folder, the script's invocation is bash assets/preflight.sh. Read references/gotcha-checks.md before using individual remedies, because some commands have broader effects than the preflight observations.

The skill refers environment preparation to a sibling resource, spark-environment-setup. That sibling is outside the supplied evidence, so a complete pinned environment and installation procedure are not established here.

example

For an undefined-symbol error before training starts, the guide directs the user to G1: inspect torch.version.cuda, check whether libcudart.so.13 can be loaded and inspect registered CUDA runtimes. This separates a PyTorch build mismatch from an unavailable runtime library.

The reference specifically warns that an NGC PyTorch build can use CUDA 13 without carrying a +cu130 package-version suffix. A missing suffix alone therefore does not justify reinstalling it. This is an illustrative diagnostic path; no output or successful repair was observed.

Assessment & evidence

limitations

A successful script process is not an overall diagnostic pass. The supplied code has no explicit aggregate failure exit status and ends with an informational echo, so printed failures need separate interpretation. Python errors are suppressed in some checks; G7's generic torch-not-importable message can also conceal other failures, such as GPU initialization problems.

The Unsloth workaround changes an internal module flag and is documented for version 2026.7.2 and models using its llama-architecture loader. Its applicability to other versions and loaders is unknown.

The G3 remedy clears the page cache system-wide and requires root. The G5 benchmark is intended for an idle host and can disrupt another workload. Its code allocates a roughly 4 GB input tensor and clones it, so memory use extends beyond the input tensor alone; actual peak allocation was not measured.

reasoning

The guide's practical value comes from connecting vague symptoms to specific observations. For example, reported GPU memory headroom may miss host-side pressure in shared memory, while a device-capability result cannot establish how a particular kernel was compiled.

Its detailed conditions matter more than the short table. G6 allows small, explicitly capped workloads to coexist despite the table's one-server shorthand. G2 distinguishes bare-pip builds from containers with bundled flash-attn. These qualifications support using the resource as a diagnostic aid while checking the actual environment before applying a remedy.

alternatives

For selective manual diagnosis, the included gotcha-checks.md can be used directly instead of the Bash wrapper. For broader setup guidance, the skill points to spark-environment-setup and NVIDIA's playbooks repository at [https://github.com/NVIDIA/dgx-spark-playbooks]. Their complete contents and current suitability were not assessed.

For the specific Unsloth attention-selection problem, the reference describes plain TRL/PEFT with Transformers as a way to bypass Unsloth's loader. It reports that the explicit SDPA setting is honored there. This is a source-reported workaround, with no comparative execution evidence supplied.

evidence

The available material contains the complete skill instructions, preflight shell script, detailed command reference and repository licence at revision 9c61ab243def98f72da12abd41cfcf5bcd91af9d.

The reference describes live observations involving flash-attn, Unsloth and concurrent workloads, but supplies no underlying execution logs or benchmark records. Those statements remain attributed documentation claims. No script or command was executed, and installation, training completion, diagnostic accuracy and performance were not tested.

Access & freshness

costs

The MIT licence permits use without a licence fee. The supplied script contains local diagnostic commands and no explicit paid API calls.

Total operating cost is unknown. The evidence supplies no hardware price, electricity cost, container-service pricing, external assistant charges or support fees. It also provides no measured time savings or financial return.

rights

The repository-level MIT licence carries Copyright (c) 2024 Seth Hobson. It permits use, copying, modification, publication, distribution, sublicensing and sale, provided the copyright and permission notices accompany copies or substantial portions. It disclaims warranties and liability.

The notice is available at [https://raw.githubusercontent.com/wshobson/agents/9c61ab243def98f72da12abd41cfcf5bcd91af9d/LICENSE]. It does not establish the separate licensing terms of referenced NVIDIA containers, external packages, model weights or datasets.

freshness

The source snapshot was captured on 17 November 2026. The command reference labels itself last verified on 14 July 2026 and calls for refreshing its guidance when CUDA, PyTorch or the DGX Spark stack receives a new major version.

Specific observations reference Unsloth 2026.7.2, flash-attn 2.7.4.post1 in an NGC 25.09-py3 container and an NGC 25.11-py3 CUDA-build example. These are documented examples, not established current recommendations. Later fixes, current upstream issues and compatibility with newer environments are unknown.

actions

Match the failing workload to its G-number and read the full reference entry before changing the environment. Treat preflight output as partial evidence: attention selection, competing processes, upstream issues and two-Spark configuration require separate inspection, and sm_121a compilation remains a manual check.

For suspected throttling, the reference calls for 10–15 minutes of representative temperature and power sampling; one snapshot is insufficient. Keep page-cache clearing between runs and the bandwidth experiment on an idle host. Recheck version-specific workarounds and performance assumptions against the actual software stack before relying on them for a long training job.

Evidence for this report

LICENSEnotice · checked 2026-11-17