unsloth/studio/scripts
Daniel Han c7fd2cf925 provision_llama_cuda: default to ~half cores (thermal headroom)
A full -j(nproc) CUDA build trips power/thermal shutdowns on thermally
constrained NVIDIA-ARM laptops (observed on the N1X "RTX Spark": a full-core
build, especially alongside other load, shuts the machine down). nice lowers
CPU *scheduling* priority but not heat -- power/heat scale with the number of
active compile jobs -- so default to ~half the cores instead: still ~2.5x
faster than a tiny -j4, but leaves real headroom. Still mem-capped (~1.5 GB
per nvcc job) and overridable via UNSLOTH_LLAMA_BUILD_JOBS (raise on a
well-cooled box, lower if it still trips). Tiny boxes (<=4 cores) use all.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 21:06:43 -07:00
..
provision_llama_cuda.sh provision_llama_cuda: default to ~half cores (thermal headroom) 2026-06-03 21:06:43 -07:00