System Design
19. AI System Design and LLM InfrastructureAnimated
Data Parallelism
Same model on each device, different data.
The idea
Each device processes a slice of the batch and gradients are averaged.
Watch it work
Press play, pause, or step through. Some animations have settings you can change.
- client
- gateway / proxy
- service
- cache
- data store
- queue / stream
Stream shards of data to every GPU worker.
- step:
- 1/4
- at:
- Dataset in object storage
1/9
The green dot is a request moving through the system.
Step by step
- 1Copy the model to every device
- 2Split the batch
- 3Compute gradients locally
- 4Average gradients and update
Where it is used
Most training.
Watch out for
The model must fit on one device.