module core.module
Global Variables
- TYPE_CHECKING
class ModuleNode
a node that extends torch.nn.Module
ModuleNode
manages neural network modules (torch.nn.Module
) and the optimizers responsible to train them. For each ModuleNode
, multiple optimizers can be specified, each of which can be responsible for different group of parameters by filtering parameters names.
Multiple ModelNode
with different training configuration under differnt tags can share a same torch.nn.Module
.
method __init__
property board
the board writer of current task.
property device
the assigned device by current launcher.
property epoch_size
the size of current epoch.
property epoch_steps
the steps of current epoch.
property global_auto_steps
the global steps of current task.
property global_train_epochs
the global train epochs of current task.
property global_train_steps
the global train steps of current task.
property grad_acc_steps
the grad accumulator steps of current task.
property grad_scaler
the grad scaler of current task.
property launcher
the current launcher.
property name
the node name in the current activated ExecutableGraph
.
property out_dir
the output directory of current task.
property run_id
the run id of current task.
property step_mode
whether current task is running by step (True) or by epoch (False).
property task
the current task.
property training
whether current task is training.