SpinTheMic
Pro

Interview practice question

Scaling training from one GPU to eight

Machine Learning · ML Frameworks · Intermediate

Your PyTorch model trains on one GPU but takes too long. How do you scale to 8 GPUs?

What a strong answer covers

Your AI report card counts how many of these ideas you cover.

  • Use DDP via torchrun (or Accelerate/Lightning).
  • DistributedSampler for data sharding.
  • Adjust batch size and learning rate.
  • Save checkpoints on rank 0; synchronize metrics.
  • FSDP if model doesn't fit.
Practise this topic

Start without signing up. Sign in free to get an AI report card on your answer.

See all topics