OperatorPredictor#

class pinnx.callbacks.OperatorPredictor(x, op, period=1, filename=None, precision=2)[source]#

Generates operator values for the input samples.

Parameters:
  • x (Dict) – The input data.

  • op (Callable) – The operator with inputs (x, y).

  • period (int) – Interval (number of epochs) between checking values.

  • filename (str) – Output the values to the file filename. The file is kept open to allow instances to be re-used. If None, output to the screen.

  • precision (int) – The precision of variables to display.

init()[source]#

Init after setting a trainer.

on_epoch_end()[source]#

Called at the end of every epoch.

on_predict_end()[source]#

Called at the end of prediction.

on_train_begin()[source]#

Called at the beginning of trainer training.

on_train_end()[source]#

Called at the end of trainer training.