Simd Library Documentation.

Home | Release Notes | Download | Documentation | Issues | GitHub | SourceForge
TrainOptions Struct Reference

Contains a set of training options. More...

Public Types

enum  InitType { Xavier }
enum  LossType {
enum  UpdateType { AdaptiveGradient }

Public Member Functions

 TrainOptions ()
 Default constructor.

Data Fields

InitType initType
 Method to initialize weights.
LossType lossType
 Loss function type.
UpdateType updateType
 Weights' update type.
size_t threadNumber
 Number of threads used to train. Use -1 to auto detect thread number.
size_t epochStart
 Start epoch. It is used to continue training process.
size_t epochFinish
 Finish epoch. Describes total epoch number.
size_t batchSize
 A batch size.
float alpha
 Describes training speed.
float epsilon
 Used to prevent division by zero.

Detailed Description

Contains a set of training options.

Member Enumeration Documentation

◆ InitType

enum InitType

Describes method to initialize weights of neural network.


Use fan-in and fan-out for scaling Xavier Glorot, Yoshua Bengio. "Understanding the difficulty of training deep feedforward neural networks" Proc. AISTATS 10, May 2010, vol.9, pp249-256

◆ LossType

enum LossType

Describes loss function.


Mean-Squared-Error loss function for regression.


Cross-entropy loss function for (multiple independent) binary classifications.


Cross-entropy loss function for multi-class classification.

◆ UpdateType

enum UpdateType

Method of weights' updating.


Adaptive gradients method. J Duchi, E Hazan and Y Singer, "Adaptive subgradient methods for online learning and stochastic optimization" The Journal of Machine Learning Research, pages 2121-2159, 2011.

See SimdNeuralAdaptiveGradientUpdate.