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

fix logging config and add profiler test #1267

Merged

Conversation

jeremyjordan
Copy link
Contributor

Before submitting

  • Was this discussed/approved via a Github issue? (no need for typos and docs improvements)
  • Did you read the contributor guideline, Pull Request section?
  • Did you make sure to update the docs?
  • Did you write any new necessary tests?
  • If you made a notable change (that affects users), did you update the CHANGELOG?

What does this PR do?

Fixes #1236

PR review

Anyone in the community is free to review the PR once the tests have passed.
If we didn't discuss your PR in Github issues there's a high chance it will not be merged.

Did you have fun?

Make sure you had fun coding 🙃

@jeremyjordan jeremyjordan requested review from williamFalcon, Borda and a team March 28, 2020 01:28
@codecov
Copy link

codecov bot commented Mar 28, 2020

Codecov Report

Merging #1267 into master will increase coverage by 0%.
The diff coverage is 100%.

@@          Coverage Diff           @@
##           master   #1267   +/-   ##
======================================
  Coverage      92%     92%           
======================================
  Files          61      61           
  Lines        3153    3154    +1     
======================================
+ Hits         2886    2887    +1     
  Misses        267     267           

@Borda Borda added the bug Something isn't working label Mar 28, 2020
@Borda Borda added this to the 0.7.2 milestone Mar 28, 2020
@jeremyjordan jeremyjordan requested review from Borda and a team March 29, 2020 13:50
Copy link
Member

@Borda Borda left a comment

Choose a reason for hiding this comment

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

Let's get it done...

@williamFalcon
Copy link
Contributor

williamFalcon commented Mar 29, 2020

@jeremyjordan what happens right now if i interrupt training for profiling?
it sounds like for the profiler to work i have to set max_epochs? is that documented?

@jeremyjordan
Copy link
Contributor Author

@williamFalcon the profiler summary gets printed (or saved to file) in run_training_teardown https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pytorch_lightning/trainer/training_loop.py#L621

this is called if:

  • KeyboardInterrupt is caught
  • epoch mets max_epochs threshold
  • early stopping is triggered
  • step mets max_steps threshold

i believe all of the cases are covered for when we want to log the profiler summary, as run_training_teardown is intended for whenever we stop a training run

@williamFalcon williamFalcon merged commit 54507f4 into Lightning-AI:master Mar 29, 2020
alexeykarnachev pushed a commit to alexeykarnachev/pytorch-lightning that referenced this pull request Mar 30, 2020
alexeykarnachev pushed a commit to alexeykarnachev/pytorch-lightning that referenced this pull request Apr 3, 2020
@Borda Borda modified the milestones: v0.7., v0.7.x Apr 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AdvancedProfiler error
4 participants