Example #1
0
 private void LearnProcess(Field.BufferField teacher)
 {
     Layers[Layers.Count - 1].property.Output.DifferenceOf(teacher, ref Layers[Layers.Count - 1].property.Sigma);
     for (int i = Layers.Count - 1; i >= 0; i--)
     {
         Layers[i].Back();
     }
 }
Example #2
0
 private void InferenceProcess(Field.BufferField input)
 {
     input.CopyTo(Layers[0].property.Input);
     for (int i = 0; i < Layers.Count; i++)
     {
         Layers[i].Forward();
     }
 }
Example #3
0
 protected void RandomNoize(ref Field.BufferField f, double noize, Random random)
 {
     for (int c = 0; c < f.Channels; c++)
     {
         for (int i = 0; i < f.Width; i++)
         {
             for (int j = 0; j < f.Height; j++)
             {
                 f.Buffer[c][i, j] += (random.NextDouble() * 2 - 1) * noize;
             }
         }
     }
 }
Example #4
0
 public void Learn(Field.BufferField input, Field.BufferField teacher)
 {
     InferenceProcess(input);
     LearnProcess(teacher);
 }