Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
self.max_cols = max_cols
self.max_epoch = max_epoch
self.metric2title = metric2title
self.series_fmt = series_fmt
if validation_fmt is not None:
# backward compatibility
self.series_fmt['validation'] = validation_fmt
self.logs = None
self.base_metrics = None
self.metrics_extrema = None
self.plot_extrema = plot_extrema
self.skip_first = skip_first
self.target = target
self._validate_target()
if target == MATPLOTLIB_TARGET:
not_inline_warning()
self.fig_path = fig_path
if tensorboard_dir:
from .tensorboard import TensorboardLogger
self.tensorboard_logger = TensorboardLogger(tensorboard_dir)
else:
self.tensorboard_logger = None
self.set_max_epoch(max_epoch)
self.extra_plots = extra_plots
self.global_step = 0