-
Notifications
You must be signed in to change notification settings - Fork 3.6k
fix info message when max training time reached #7780
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #7780 +/- ##
======================================
- Coverage 93% 92% -0%
======================================
Files 199 199
Lines 12985 12986 +1
======================================
- Hits 12018 11981 -37
- Misses 967 1005 +38 |
ca5934b to
d5ce796
Compare
| assert "Time limit reached." in caplog.text | ||
| assert "Signaling Trainer to stop." in caplog.text |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| assert "Time limit reached." in caplog.text | |
| assert "Signaling Trainer to stop." in caplog.text | |
| assert re.match(r"Time limit reached. Elapsed time is .*\. Signaling Trainer to stop.", caplog.text) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@justusschock mind rather use reg expresions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@awaelchli ^^
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Borda it wouldn't work.
Not even
assert re.match(r".*Time limit reached.*", caplog.text)
wants to match.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import re
m = "Time limit reached. Elapsed time is any text here I want. Signaling Trainer to stop."
assert re.match(r"Time limit reached. Elapsed time is .*\. Signaling Trainer to stop.", m)or what is in the caplog.text?
* call time_elapsed * elapsed formatting * format * update test * changelog
* call time_elapsed * elapsed formatting * format * update test * changelog
* call time_elapsed * elapsed formatting * format * update test * changelog
* call time_elapsed * elapsed formatting * format * update test * changelog
What does this PR do?
Fixes #7778
Fixes incorrect formatting of time remaining.
Now shows a message properly formatted:
Before submitting
PR review
Anyone in the community is free to review the PR once the tests have passed.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:
Did you have fun?
Make sure you had fun coding 🙃