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

feat: Early stopping can be used in Reader and Retriever training #3071

Merged
merged 25 commits into from
Aug 23, 2022
Merged

Conversation

sjrl
Copy link
Contributor

@sjrl sjrl commented Aug 19, 2022

Related Issues

No issue

Proposed Changes:

Add option to specify Early Stopping in the Reader trainer. This feature is already present, I just exposed the option to the FARMReader.train method.

How did you test it?

I've run a Reader training using Early Stopping on AWS and it worked as expected.

Notes for the reviewer

Checklist

@sjrl sjrl requested a review from a team as a code owner August 19, 2022 13:15
@sjrl sjrl requested review from bogdankostic and removed request for a team August 19, 2022 13:15
@sjrl sjrl requested a review from a team as a code owner August 19, 2022 13:20
haystack/modeling/training/base.py Outdated Show resolved Hide resolved
Copy link
Contributor

@brandenchan brandenchan left a comment

Choose a reason for hiding this comment

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

Making a set of suggestions for improvements to the docstrings

haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
docs/_src/api/pydoc/utils.yml Outdated Show resolved Hide resolved
sjrl and others added 14 commits August 22, 2022 15:10
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
Co-authored-by: Branden Chan <33759007+brandenchan@users.noreply.github.com>
@sjrl
Copy link
Contributor Author

sjrl commented Aug 23, 2022

@bogdankostic This PR is ready for review :)

Copy link
Contributor

@bogdankostic bogdankostic left a comment

Choose a reason for hiding this comment

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

Looking good to me! I assume you moved EarlyStopping to utils/early_stopping.py for documentation?

@sjrl
Copy link
Contributor Author

sjrl commented Aug 23, 2022

I assume you moved EarlyStopping to utils/early_stopping.py for documentation?

That is correct!

@sjrl
Copy link
Contributor Author

sjrl commented Aug 23, 2022

@brandenchan @agnieszka-m I would appreciate another review and an approval if you are happy with the changes.

@brandenchan brandenchan self-requested a review August 23, 2022 10:23
Copy link
Contributor

@agnieszka-m agnieszka-m left a comment

Choose a reason for hiding this comment

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

Minor lg comments

docs/_src/api/api/retriever.md Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
haystack/utils/early_stopping.py Outdated Show resolved Hide resolved
@sjrl sjrl changed the title feat: Add option to set early stopping feat: Early stopping can be used in Reader and Retriever training Aug 23, 2022
@sjrl sjrl merged commit 3ea5780 into main Aug 23, 2022
@sjrl sjrl deleted the early_stop branch August 23, 2022 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic:reader type:feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants