torch:train
(torch:train module &optional mode)
Puts the module and every submodule into training mode (PyTorch's nn.Module.train) and returns the module; an explicit nil mode is the same as torch:eval. Only torch:dropout reads the flag today.