AI Hardware & Software Stack

Which describes data parallelism in multi-GPU training?

  1. AEach GPU holds a full model replica, computes on its share of the data, and gradients are averaged across GPUs before updating weights
  2. BModel layers are split so each GPU handles different layers
  3. COne GPU computes while the others stand by
Show answer and explanation

Answer: A. Each GPU holds a full model replica, computes on its share of the data, and gradients are averaged across GPUs before updating weights

In data parallelism, every GPU holds the same model, the training batch is divided among them, and each performs forward and backward passes. Their gradients differ, so an all-reduce communication sums and averages gradients across GPUs, and everyone updates weights with the same gradient, keeping the replicas identical. It is simple and effective when the model fits on one GPU, but communication grows heavier as GPUs are added.

  • A. Correct. It is the most basic parallel approach.
  • B. That is pipeline parallelism.
  • C. That is not parallel at all.
Practice this topic Back to topic

More AI Hardware & Software Stack questions

  1. Which describes tensor parallelism, which splits a large layer's matrix multiplication too big for one GPU across several GPUs?
  2. In pipeline parallelism, where a model's layers are split across GPUs in sequence, why is a batch divided into micro-batches?
  3. What does the all-reduce communication used in distributed training do?
  4. Which describes gradient checkpointing (activation recomputation) used in training?
  5. What is the main reason systolic arrays in AI accelerators compute matrix products efficiently?