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 save the trained model and use for final test like demo? #28

Open
DL8614 opened this issue Jan 23, 2020 · 1 comment
Open

How to save the trained model and use for final test like demo? #28

DL8614 opened this issue Jan 23, 2020 · 1 comment

Comments

@DL8614
Copy link

DL8614 commented Jan 23, 2020

Hi,
I am training the model with my own dataset and I am saving the model with
torch.save(classifier.state_dict(), PATH)

However, when I load it, it shows IncompatibleKeys(missing_keys=[], unexpected_keys=[])
It looks that, it saves nothing? How can I save it?

One other question is that. if validation loss looks very low. Then how can I use that trained model with some unknown graph for graph class prediction?

@muhanzhang
Copy link
Owner

It looks like it is saving the model, with no keys missing or unexpected. Maybe this post helps you?

For your second question, do you mean validation accuracy (instead of loss) very low? If so, it is better to tune the architecture/hyperparameters to make it high before applying to unknown graphs.

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