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

Remove deprecated Trainer::update_epoch #852

Merged
merged 2 commits into from
Sep 4, 2017

Conversation

tetsuok
Copy link
Contributor

@tetsuok tetsuok commented Sep 3, 2017

This PR removes the deprecated method call used in the examples.
The method was deprecated in #695.


This change is Reviewable

Copy link
Contributor

@neubig neubig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you completely remove the first variable from these examples? Then I'll be happy to merge.

@@ -156,7 +156,7 @@ int main(int argc, char** argv) {
for (unsigned i = 0; i < report_every_i; ++i) {
if (si == training.size()) {
si = 0;
if (first) { first = false; } else { sgd->update_epoch(); }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this is great. We can also probably remove the "first" variable entirely, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Please take a look.

@neubig neubig merged commit cb24072 into clab:master Sep 4, 2017
@neubig
Copy link
Contributor

neubig commented Sep 4, 2017

Thanks!

@tetsuok tetsuok deleted the remove-deprecated branch September 4, 2017 11:28
tetsuok added a commit to tetsuok/dynet that referenced this pull request Sep 9, 2017
neubig pushed a commit that referenced this pull request Sep 10, 2017
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

Successfully merging this pull request may close these issues.

2 participants