sciai.common.LeCunNormal

View Source On Gitee
class sciai.common.LeCunNormal[source]

Yann LeCun Normal Initialization N(0,sigma2) in order to initialize a tensor, where

sigma=1fan_in

'fan_in' is the number of input units of the weight tensor.

For details of LeCun Normal Initialization, please check: Neural Tangent Kernel: Convergence and Generalization in Neural Networks.

Supported Platforms:

GPU CPU Ascend

Examples

>>> import mindspore
>>> from mindspore.common.initializer import initializer
>>> from sciai.common.initializer import LeCunNormal
>>> tensor = initializer(LeCunNormal(), [1, 2, 3], mindspore.float32)