allennlp
allennlp copied to clipboard
Feature request: log entire config to tensorboard as text field
:exclamation: NOTE: implementing this feature kind of depends on this bug in tensorboardX
being resolved: https://github.com/lanpa/tensorboardX/issues/345
Is your feature request related to a problem? Please describe. My TensorBoard gets really crowded as I often make multiple runs of the same config after making slight alterations. It then becomes difficult to figure out exactly which parameters are associated with each run unless you actually create a separate config for each small change (do-able but annoying) or record each change in a git commit (also annoying).
Describe the solution you'd like
It would really convenient if we could view the configs directly in TB. This can be done, in theory, by logging them as text fields. I have a branch where I've hacked this together: https://github.com/epwalsh/allennlp/tree/log-config. Unfortunately the bug with tensorboardX
prevents this from working as of now. So I suppose we could just wait to see if that gets resolved or find another method.
This would be cool! @matt-gardner mentioned wanting this just the other day, actually. Could you ping this issue when the underlying bug is resolved? Contributions are most certainly welcome...
@brendan-ai2 will do!
Another potential solution would be to use PyTorch's tensorboard interface, instead of tensorboardX. See https://github.com/pytorch/pytorch/releases/tag/v1.1.0. Or maybe with the upcoming trainer callbacks refactoring we could also provide a callback for the config, allowing the user to get it into Tensorboard with whatever method works for them.
Hi, As FYI, I have exposed writer.flush()
in https://github.com/lanpa/tensorboardX/commit/e9323109eab780a7444508e95f9d3a49e1f4f59f
@lanpa thanks for the update! I will check it out