这篇文章来介绍一下MegatronLM中DataParallel相关的实现,适合希望阅读源码的同学来看 主要会涉及到DDP/FSDP,distributed optimizer会单独再出一篇文章。 官方有一篇设计文档,可以简单看看https://docs.nvidia.com/megatron-core/developer-guide/latest/api-guide/custom_fsdp.html# DDP MegatronLM中DDP的代码主要在core/distributed/distributed…