已开启
[Bug] MindSpore FSDP register_hook 每次前向传播累积导致性能劣化 #210
hedongdong创建于 6月12日
6月12日 添加了label:bug
Hhedongdong
6月12日 关联了pull request:fix(mindspore-fsdp): prevent hook accumulation causing performance degradation
6月12日 关联了pull request:fix(mindspore-fsdp): prevent hook accumulation causing performance degradation
该问题是怎么引起的?
MindSpore FSDP Scheduler 中
_backward_pre_hook使用register_hook注册钩子,每次前向传播都会在 tensor 上累积新的 hook,未被清理,导致随着训练步数增加性能逐渐劣化。
重现步骤
报错信息
无明显报错,但训练速度随步数增加显著下降。