3/34
Part 1 of 5 · The round and the clusterLearn and do
Who shares the cluster, and what each job asks for
Before any queue, know who submits work, and what each kind of work wants.
Five kinds of work want different things
| Workload | Shape | Duration | Wants | Tolerates |
|---|---|---|---|---|
| Distributed training | 8 to 256 GPUs that must start together | hours to weeks | all GPUs at once, close together | waiting in the queue, restarts from a checkpoint |
| Batch inference | thousands of independent 1-GPU shards | minutes per shard | throughput and a deadline | preemption of single shards |
| Hyperparameter sweeps | hundreds of small trials | minutes to hours | many GPUs cheaply | preemption, spot capacity |
| Notebooks | 1 GPU, interactive | a working day, mostly idle | to start in under a minute | not much |
| CPU jobs (features, Spark, data prep) | many CPU-only tasks | minutes to hours | CPU and memory | landing on CPU nodes only |
Name these differences before you draw anything. A training job can't start until all of its GPUs can. A sweep takes whatever is cheap and spare. A notebook wants a GPU right now and then barely uses it.
Four needs cut across all five:
- Mixed hardware. Several GPU generations and node shapes, and jobs that can run on more than one. The authors of Gavel, a scheduler built for this, found that an accelerator's speed depends on the model's architecture. The newest GPU can speed one model up far more than another.
- Team quotas. Each team is guaranteed a share and wants to borrow idle capacity.
- Priorities and deadlines. A production retrain that feeds tomorrow's homepage beats a research sweep.
- Utilization. Idle GPUs are the expensive mistake.
In the editor, write start_together(job) and preemptible(job): the table's Shape and Tolerates columns as code. Each dict in JOBS is one kind of work, with its GPUs and, for training, whether it checkpoints.