Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

project_configuration.automatic_checkpoint_naming synchronization between load_state and save_state #3306

Open
diffunity opened this issue Dec 19, 2024 · 0 comments

Comments

@diffunity
Copy link

I am having trouble finding ways to synchronize the checkpoint names configured by save_state with that used by load_state.

What I mean is when we save_state with project_configuration.automatic_checkpoint_naming = True, a checkpoint folder is created at output_dir/checkpoint_0 and the accelerator object keeps track of the checkpoint iterations with the class variable self.project_configuration.iteration at here.

If I reinitialize the accelerator object and load_state on, say, output_dir/checkpoint_5. The self.project_configuration.iteration is initialized at 0 for this new accelerator object. Therefore, if I do save_state, it saves to output_dir/checkpoint_0. Is there a way to synchronize this class variable during load_state so that I don't have to designate the exact checkpoint iteration?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant