Ignore modules
Summary: Pull Request resolved: https://github.com/facebookresearch/d2go/pull/470 Enable ignore FSDP modules. Those modules will not be put in FSDP. It is useful in the diffusion model, where the CLIP model is not used in training. Thus, it is OK to have a separate copy in each GPU. It reduces the CLIP execution time from 63ms to 48ms (15ms reduction). This is mostly because it is a CPU bounded module and in each FSDP block, some code is injected. In addition, it also reduces the FSDP all gather time before the CLIP execution from 56ms to 7ms (49ms reduction). In total, this change may reduce the CLIP runtime from 119ms to 64ms (63ms reduction) This feature is controlled by this flag: IGNORED_MODULES: ["clip_model"] Reviewed By: newstzpz Differential Revision: D42910383 fbshipit-source-id: dc4c12254d45ac45d88329feb63a26ec4ae04aef
Showing
Please register or sign in to comment