public override NeuronLayer CreateInputLayer(int countNeurons)
        {
            //if (inputSignal.Count == countNeurons)
            //{
                NeuronLayer layer = new NeuronLayer();

                for (int i = 0; i < countNeurons; i++)
                {
                    Synapse synapse = new Synapse();
                    Neuron neuron = new Neuron(new LinearFunction());

                    //synapse.SetSignal(inputSignal[i]);
                    synapse.SetWeight(1);
                    neuron.SetShift(0);

                    synapse.SetParentNeurons(null, neuron);

                    neuron.AddInput(synapse);

                    layer.AddNeuron(neuron);
                }

                network.SetInputLayer(layer);

                return layer;
            //}
            //else
            //{
            //    MessageBox.Show("lol ... countNeurons не равно signal.Count");
            //    return null;
            //}
        }
        public override NeuronLayer CreateOutputLayer(int countNeurons)
        {
            NeuronLayer layer = new NeuronLayer();

            for (int i = 0; i < countNeurons; i++)
            {
                Neuron neuron = new Neuron(new SigmoidFunction());
                Synapse synapse = new Synapse();

                synapse.SetWeight(1);

                synapse.SetParentNeurons(neuron, null);
                neuron.AddOutput(synapse);

                layer.AddNeuron(neuron);
            }

            network.SetOutputLayer(layer);

            return layer;
        }