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

It's ridiculous saving the best model every epoch on Clothing1M #12

Open
lxysl opened this issue Mar 2, 2024 · 0 comments
Open

It's ridiculous saving the best model every epoch on Clothing1M #12

lxysl opened this issue Mar 2, 2024 · 0 comments

Comments

@lxysl
Copy link

lxysl commented Mar 2, 2024

# in val() function:
  if acc > best_acc[k-1]:
      best_acc[k-1] = acc
      print('| Saving Best Net%d ...'%k)
      save_point = os.path.join(model_save_loc, '%s_net%d.pth.tar'%(args.id,k))
      torch.save(net.state_dict(), save_point)

In each epoch, you load the state_dict from the previous best model and then train it two or three times. If the new model gets a better score, then save it. As all know, LNL methods tend to suffer performance decreases as training goes on, and this is particularly obvious in Clothing1M. So I think it's an unfair comparison unless remove these lines.

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