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

[Bug Fix] Allow logger to support indexing #4595

Merged
merged 10 commits into from
Dec 5, 2020

Conversation

zippeurfou
Copy link
Contributor

@zippeurfou zippeurfou commented Nov 9, 2020

What does this PR do?

This should fix #4540

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 your PR does only one thing, instead of bundling different changes together? Otherwise, we ask you to create a separate PR for every change.
  • na Did you make sure to update the documentation with your changes?
  • na Did you write any new necessary tests?
  • Did you verify new and existing tests pass locally with your changes?
  • na If you made a notable change (that affects users), did you update the CHANGELOG?

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 in short, see following bullet-list:

  • Is this pull request ready for review? (if not, please submit in draft mode)
  • Check that all items from Before submitting are resolved
  • Make sure the title is self explanatory and the description concisely explains the PR
  • Add labels and milestones (and optionally projects) to the PR so it can be classified; Bugfixes should be including in bug-fix release milestones (m.f.X) and features should be included in (m.X.b) releases.

Did you have fun?

Make sure you had fun coding 🙃

@pep8speaks
Copy link

pep8speaks commented Nov 9, 2020

Hello @zippeurfou! Thanks for updating this PR.

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2020-12-05 20:10:44 UTC

@zippeurfou zippeurfou force-pushed the fix-4540/logger-indexing branch 4 times, most recently from 086d19d to a3997fe Compare November 9, 2020 21:26
@codecov
Copy link

codecov bot commented Nov 9, 2020

Codecov Report

Merging #4595 (b61a77c) into master (16fa4ed) will increase coverage by 3%.
The diff coverage is 100%.

@@           Coverage Diff           @@
##           master   #4595    +/-   ##
=======================================
+ Coverage      90%     93%    +3%     
=======================================
  Files         129     129            
  Lines        9359    9363     +4     
=======================================
+ Hits         8411    8681   +270     
+ Misses        948     682   -266     

@SkafteNicki
Copy link
Member

Hi @zippeurfou
Please include a test that would currently fail on master but pass with this PR :]

@zippeurfou
Copy link
Contributor Author

Sure happy to do so.

@zippeurfou zippeurfou force-pushed the fix-4540/logger-indexing branch from a3997fe to f862e81 Compare November 12, 2020 20:30
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.

@SkafteNicki mind bring a bit light on how this fixes the LF issue?
eventually, this yields an infinite loop if you have miss LoggerCollection and base logger

@SkafteNicki
Copy link
Member

@Borda the problem currently is that neither DummyExperiment and DummyLogger supports indexing, so if the users has something like this in their code:
self.logger[0].experiment.add_image(...)
or
self.logger.experiment[0].add_image(...)
currently lr finder will crash as it temporarily replaces the user logger with a DummyLogger.

Can you elaborate in which case this can give an infinite loop?

Copy link
Contributor

@tchaton tchaton left a comment

Choose a reason for hiding this comment

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

Looks slightly weird to me. Do you have any other solution in mind ?

@awaelchli awaelchli added the logger Related to the Loggers label Nov 22, 2020
@Borda Borda requested review from tchaton and Borda November 30, 2020 19:57
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.

lgtm

@Borda Borda added design Includes a design discussion bug Something isn't working labels Nov 30, 2020
@Borda Borda added this to the 1.1 milestone Nov 30, 2020
@Borda Borda added the ready PRs ready to be merged label Nov 30, 2020
@SeanNaren SeanNaren merged commit 849737e into Lightning-AI:master Dec 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working design Includes a design discussion logger Related to the Loggers ready PRs ready to be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Existing logger conflict with lr_finder
8 participants