Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix bmuf restart causing lr to be reset
Summary: From https://fb.workplace.com/groups/332923290658088/permalink/505568510060231/, we have observed that learning rate on resume is reset to original value. Based on investigation in https://fb.workplace.com/groups/332923290658088/permalink/505568510060231/?comment_id=506348519982230, it seems like this happens 500 iterations after restarting, which coincides with BMUF warmup. After further debugging, ti seems like this is confirmed to be due to bmuf and because after warmup we reset the optimizer to the initial state when created. My proposed fix is to reset the initial state of the optimizer whenever we load the state dict. Reviewed By: zhengwy888 Differential Revision: D19183595 fbshipit-source-id: 4cdc13378817a7e9a6b658010b152a508991971f
- Loading branch information