Exemple #1
0
        public virtual void AddInputNeuron(INeuron neuron)
        {
            ISynapse synapse;

            if (neuron.GetType() == typeof(InputNeuron))
            {
                synapse = new Synapse(neuron, this, neuron.Outputs[0].Weight);
                Inputs.Add(synapse);
            }
            else
            {
                synapse = new Synapse(neuron, this);
                Inputs.Add(synapse);
                neuron.Outputs.Add(synapse);
            }
        }
 private bool IsBias(INeuron neuron)
 {
     return(neuron.GetType() == typeof(BiasNeuron));
 }
Exemple #3
0
 private bool IsBias(INeuron neuron)
 {
     return neuron.GetType() == typeof (BiasNeuron);
 }