예제 #1
0
        void Panel1_MouseWheel(object sender, MouseEventArgs e)
        {
            float width = splitContainer1.Panel1.Width / (net.NeuronGroupsCount + 1);
            int   layer = (int)(e.X / width);
            int   add   = e.Delta > 0 ? 1 : -1;

            if (layer >= net.NeuronGroupsCount)
            {
                return;
            }

            if (layer == 0)
            {
                net.InputsCount += add;
            }
            else
            {
                net.SetNeuronsCount(layer - 1, net.NeuronGroups[layer - 1].Neurons.Count + add);
            }

            netOptions.UpdateNetInformation();
        }
예제 #2
0
 private void neuronsCount_ValueChanged(object sender, EventArgs e)
 {
     net.SetNeuronsCount((int)groupNumber.Value - 1, (int)neuronsCount.Value);
 }