Skip to content

Noisy file detection method and its design #579

Answered by ashleve
pythonista-blitz asked this question in Q&A
Discussion options

You must be logged in to vote
  1. After training or testing starts you can access self.datamodule inside LightningModule.
  2. I think saving files from on_test_end hook is fine
  3. You can access loggers through self.logger (if there's one) or self.loggers list (if you use many at once). Take a look at docs to see what tensorboard properties are accessible.

The cleanest approach would probably be to write a callback dedicated to saving those images (you can access both datamodule and lightningmodule inside the callback hooks). This way you could decouple datamodule-related behavior from ligtningmodule.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by pythonista-blitz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants