Struct neuronika::nn::ModelStatus [−][src]
pub struct ModelStatus { /* fields omitted */ }
Expand description
A model’s components status.
This struct should be used when you are interested in keeping track of the statuses and the parameters of the components that are part of a neural network. There are many circumstances in which this can be useful, such as when you have more than one model in a pipeline.
This struct stores all the Learnable
associated to a given model and the model’s status. It
is suggested to perform the registration of the layers at the model construction.
Implementations
Returns a vector of Param
linked to the learnable weights associated to a neural
network.
Conceptually, this method behaves similarly to .parameters()
when
called on the differentiable variable outputted by the network. The key difference lies in
that, while the differentiable variable’s .parameters()
method would return all
the differentiable leaves that took part in the computation of the output, possibly also
the weights of another network, ModelStatus
’s .parameters()
method returns only the
leaves that have been associated with it at the model’s instantiation.
Usually the result of this method is passed to an optimizer.