AI::MXNet::Callback - A collection of predefined callback functions
module_checkpoint
Callback to save the module setup in the checkpoint files.
Parameters
----------
$mod : subclass of AI::MXNet::Module::Base
The module to checkpoint.
$prefix : str
The file prefix to checkpoint to
$period=1 : int
How many epochs to wait before checkpointing. Default is 1.
$save_optimizer_states=0 : Bool
Whether to save optimizer states for later training.
Returns
-------
$callback : sub ref
The callback function that can be passed as iter_end_callback to fit.
log_train_metric
Callback to log the training evaluation result every period.
Parameters
----------
$period : Int
The number of batches after which to log the training evaluation metric.
$auto_reset : Bool
Whether to reset the metric after the logging.
Returns
-------
$callback : sub ref
The callback function that can be passed as iter_epoch_callback to fit.
NAME
AI::MXNet::Speedometer - A callback that logs training speed
DESCRIPTION
Calculate and log training speed periodically.
Parameters
----------
batch_size: int
batch_size of data
frequent: int
How many batches between calculations.
Defaults to calculating & logging every 50 batches.
NAME
AI::MXNet::ProgressBar - A callback to show a progress bar.
DESCRIPTION
Shows a progress bar.
Parameters
----------
total: Int
batch size, default is 1
length: Int
the length of the progress bar, default is 80 chars
NAME
AI::MXNet::LogValidationMetricsCallback - A callback to log the eval metrics at the end of an epoch.
Module Install Instructions
To install AI::MXNet, copy and paste the appropriate command in to your terminal.