Trainer#

Trainer module.

class Trainer(solver, batch_size=None, **kwargs)[source]#

Bases: Trainer

PINA Trainer class for costumizing every aspect of training via flags.

Parameters:
  • solver (SolverInterface) – A pina:class:SolverInterface solver for the differential problem.

  • batch_size (int | None) – How many samples per batch to load. If batch_size=None all samples are loaded and data are not batched, defaults to None.

Keyword Arguments:

The additional keyword arguments specify the training setup and can be choosen from the pytorch-lightning Trainer API

train(**kwargs)[source]#

Train the solver method.

property solver#

Returning trainer solver.