コード例 #1
0
ファイル: LayerLink.cs プロジェクト: yafta98/MLearning-UI
 public LayerLink(int inputLength, int outputLength)
 {
     this.inputLength  = inputLength;
     this.outputLength = outputLength;
     weights           = new WeightMatrix(outputLength, inputLength);
     biases            = new BiasVector(outputLength);
 }
コード例 #2
0
 public NetworkGradient(NetworkSize size)
 {
     this.weightAdditives = new WeightMatrix[size.InternalLayerCount - 1];
     this.biasAdditives   = new BiasVector[size.InternalLayerCount - 1];
     for (int index = 0; index < weightAdditives.Length; index++)
     {
         weightAdditives[index] = new WeightMatrix(size.InternalLayerLengths[index + 1], size.InternalLayerLengths[index]);
         biasAdditives[index]   = new BiasVector(index + 1);
     }
 }