Caffe2 - C++ API
A deep learning, cross platform ML framework
Public Member Functions
torch::nn::BatchNormOptions Struct Referenceabstract

Options for the BatchNorm module. More...

#include <batchnorm.h>

Public Member Functions

 BatchNormOptions (int64_t features)
 
 TORCH_ARG (int64_t, features)
 The number of features of the input tensor. More...
 
 TORCH_ARG (bool, affine)
 Whether to learn a scale and bias that are applied in an affine transformation on the input. More...
 
 TORCH_ARG (bool, stateful)
 Whether to store and update batch statistics (mean and variance) in the module. More...
 
 TORCH_ARG (double, eps)
 The epsilon value added for numerical stability. More...
 
 TORCH_ARG (double, momentum)=0.1
 A momentum multiplier for the mean and variance. More...
 

Detailed Description

Options for the BatchNorm module.

Definition at line 13 of file batchnorm.h.

Member Function Documentation

torch::nn::BatchNormOptions::TORCH_ARG ( int64_t  ,
features   
)

The number of features of the input tensor.

Changing this parameter after construction has no effect.

torch::nn::BatchNormOptions::TORCH_ARG ( bool  ,
affine   
)

Whether to learn a scale and bias that are applied in an affine transformation on the input.

Changing this parameter after construction has no effect.

torch::nn::BatchNormOptions::TORCH_ARG ( bool  ,
stateful   
)

Whether to store and update batch statistics (mean and variance) in the module.

If false, you should call pure_forward and supply those batch statistics yourself. Changing this parameter after construction has no effect.

torch::nn::BatchNormOptions::TORCH_ARG ( double  ,
eps   
)

The epsilon value added for numerical stability.

Changing this parameter after construction is effective.

torch::nn::BatchNormOptions::TORCH_ARG ( double  ,
momentum   
)
pure virtual

A momentum multiplier for the mean and variance.

Changing this parameter after construction is effective.


The documentation for this struct was generated from the following files: