Chapter 231 / 4
Infrastructure, Distributed Training & Scaling
Implement a function computing total per-GPU memory for a given model/parallelism conf
Easy
Implement a function computing total per-GPU memory for a given model/parallelism config.
Target interface
memory_report(num_params, dp=1, tp=1, pp=1, zero_stage=0, bytes_weight=2, bytes_grad=2, bytes_optim=12)Implement the function/class skeleton in the editor. Any correct approach is accepted.
Hints0 / 2
Reference solution
Your own code stays in the editor.