ray.tune.logger.TBXLoggerCallback#

class ray.tune.logger.TBXLoggerCallback[source]#

Bases: ray.tune.logger.logger.LoggerCallback

TensorBoardX Logger.

Note that hparams will be written only after a trial has terminated. This logger automatically flattens nested dicts to show on TensorBoard:

{“a”: {“b”: 1, “c”: 2}} -> {“a/b”: 1, “a/c”: 2}

PublicAPI: This API is stable across Ray releases.

log_trial_start(trial: Trial)[source]#

Handle logging when a trial starts.

Parameters

trial – Trial object.

log_trial_result(iteration: int, trial: Trial, result: Dict)[source]#

Handle logging when a trial reports a result.

Parameters
  • trial – Trial object.

  • result – Result dictionary.

log_trial_end(trial: Trial, failed: bool = False)[source]#

Handle logging when a trial ends.

Parameters
  • trial – Trial object.

  • failed – True if the Trial finished gracefully, False if it failed (e.g. when it raised an exception).