This module contains Tensorboard monitor interface

class neural_pipeline.builtin.monitors.tensorboard.TensorboardMonitor(fsm: neural_pipeline.utils.file_structure_manager.FileStructManager, is_continue: bool, network_name: str = None)[source]

Class, that manage metrics end events monitoring. It worked with tensorboard. Monitor get metrics after epoch ends and visualise it. Metrics may be float or np.array values. If metric is np.array - it will be shown as histogram and scalars (scalar plots contains mean valuse from array).

  • fsm – file structure manager
  • is_continue – is data processor continue training
  • network_name – network name
update_losses(losses: {}) → None[source]

Update monitor

Parameters:losses – losses values with keys ‘train’ and ‘validation’
update_metrics(metrics: {}) → None[source]

Update monitor

Parameters:metrics – metrics dict with keys ‘metrics’ and ‘groups’
update_scalar(name: str, value: float, epoch_idx: int = None) → None[source]

Update scalar on tensorboard

  • name – the classic tag for TensorboardX
  • value – scalar value
  • epoch_idx – epoch idx. If doesn’t set - use last epoch idx stored in this class
visualize_model(model: neural_pipeline.data_processor.model.Model, tensor) → None[source]

Visualize model graph

  • modeltorch.nn.Module object
  • tensor – dummy input for trace model
write_to_txt_log(text: str, tag: str = None) → None[source]

Write to txt log

  • text – text that will be writed
  • tag – tag


This module contains Matplotlib monitor interface

class neural_pipeline.builtin.monitors.mpl.MPLMonitor[source]

This monitor show all data in Matplotlib plots

realtime(is_realtime: bool) → neural_pipeline.builtin.monitors.mpl.MPLMonitor[source]

Is need to show data updates in realtime

Parameters:is_realtime – is need realtime
Returns:self object
update_losses(losses: {})[source]

Update losses on monitor

Parameters:losses – losses values dict with keys is names of stages in train pipeline (e.g. [train, validation])
update_metrics(metrics: {}) → None[source]

Update metrics on monitor

Parameters:metrics – metrics dict with keys ‘metrics’ and ‘groups’