set_opt_hparams {luz}R Documentation

Set optimizer hyper-parameters

Description

This function is used to define hyper-parameters for the optimizer initialization method.

Usage

set_opt_hparams(module, ...)

Arguments

module

An nn_module that has been setup().

...

The parameters passed here will be used to initialize the optimizers. For example, if your optimizer is optim_adam and you pass lr=0.1, then the optim_adam function is called with optim_adam(parameters, lr=0.1) when fitting the model.

Value

The same luz module

See Also

Other set_hparam: set_hparams()


[Package luz version 0.4.0 Index]