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

How to re-traning when stop #142

Open
nguoido opened this issue Jun 9, 2021 · 1 comment
Open

How to re-traning when stop #142

nguoido opened this issue Jun 9, 2021 · 1 comment

Comments

@nguoido
Copy link

nguoido commented Jun 9, 2021

I have run code "train.py". But I stop it.
I wonder if I can how to re-train with the latest checkpoint?
Please help me.

@vjsyong
Copy link

vjsyong commented Jul 5, 2021

You can modify the training code by adding

model.load_weights(weight_file)

before

model.fit()

This will restore the weights from the checkpoint file, but do be aware of the learning rate as the original learning rate decays in the later epochs, so by restarting the training from epoch 0 with the already trained weights, you might have to make some modifications.

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

2 participants