线性回归基础学习
目录:
- 理论知识
- 样例代码测试
- 参考文献
一、理论知识

- NDArray:MXNet中存储和变换数据的主要工具,提供GPU计算和自动求梯度等功能
- 线性回归可以用神经网络图表示,也可以用矢量计算表示
- 在Gluon中,data模块提供了有关数据处理的工具,nn模块定义了大量神经网络的层,loss模块定义了各种损失函数
- 在MXNet的init模块(initializer)提供了模型参数化的各种方法
- 模型变量net是一个Sequential实例,Sequential实例可以看作是一个串联各个层的容器。当给定输入数据时,容器中每一层将依次计算并将输出作为下一层的输入
- MXNet.init模块中提供的初始化方法:
-
Bilinear
()Initialize weight for upsampling layers.
Constant
(value)Initializes the weights to a given value.
FusedRNN
(init, num_hidden, num_layers, mode)Initialize parameters for fused rnn layers.
Descriptor for the initialization pattern.
Initializer
(**kwargs)The base class of an initializer.
LSTMBias
([forget_bias])Initialize all biases of an LSTMCell to 0.0 except for the forget gate whose bias is set to custom value.
Load
(param[, default_init, verbose])Initializes variables by loading data from file or dict.
MSRAPrelu
([factor_type, slope])Initialize the weight according to a MSRA paper.
Mixed
(patterns, initializers)Initialize parameters using multiple initializers.
Normal
([sigma])Initializes weights with random values sampled from a normal distribution with a mean of zero and standard deviation of sigma.
One
()Initializes weights to one.
Orthogonal
([scale, rand_type])Initialize weight as orthogonal matrix.
Uniform
([scale])Initializes weights with random values uniformly sampled from a given range.
Xavier
([rnd_type, factor_type, magnitude])Returns an initializer performing “Xavier” initialization for weights.<
-