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

specifying modes train, validation and test #60

Open
fansariadeh opened this issue Apr 19, 2020 · 1 comment
Open

specifying modes train, validation and test #60

fansariadeh opened this issue Apr 19, 2020 · 1 comment

Comments

@fansariadeh
Copy link

Hi guys!

I hope any of you happen to know why in line 88 of train.py, while it tries to specifies test mode, we see these line:
def test():
model.eval()
Dont you think it should be ### model.test() ### sine we are focusing on test set?

Thank you in advance guys.

@chao1224
Copy link

chao1224 commented May 7, 2020

@fansariadeh There's no model.test() in pytorch.
When you train the model, call model.train() will activate some layers like batch-norm, zero-out.
When you test the model, call model.eval() will modify the operations through these layers.

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