Unverified Commit 2872f967 authored by Brian Yu's avatar Brian Yu Committed by GitHub
Browse files

TensorBoard callback no longer adds hparams (#23999)

tensorboard callback no longer adds hparams
parent 44bd590a
...@@ -639,9 +639,6 @@ class TensorBoardCallback(TrainerCallback): ...@@ -639,9 +639,6 @@ class TensorBoardCallback(TrainerCallback):
if hasattr(model, "config") and model.config is not None: if hasattr(model, "config") and model.config is not None:
model_config_json = model.config.to_json_string() model_config_json = model.config.to_json_string()
self.tb_writer.add_text("model_config", model_config_json) self.tb_writer.add_text("model_config", model_config_json)
# Version of TensorBoard coming from tensorboardX does not have this method.
if hasattr(self.tb_writer, "add_hparams"):
self.tb_writer.add_hparams(args.to_sanitized_dict(), metric_dict={})
def on_log(self, args, state, control, logs=None, **kwargs): def on_log(self, args, state, control, logs=None, **kwargs):
if not state.is_world_process_zero: if not state.is_world_process_zero:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment