예제 #1
0
파일: LayerF2.cs 프로젝트: DrUzair/CompoNet
        public int AddF2Neuron(LayerF1 f1Layer, double[] tdConnWeights, double [] prototype) // to be called from CAFuzzyART(string path) method where pattern != tdConnweights
        {
            F2Neuron newF2Neuron = new F2Neuron(f1Layer.Count);

            base.Add(newF2Neuron);
            SynapticConnection[] connections = newF2Neuron.getConnections();
            for (int i = 0; i < connections.Length; i++)
            {
                connections[i].setF1Neuron((F1Neuron)f1Layer[i]);
                connections[i].setF2Neuron(newF2Neuron);
                ((F1Neuron)f1Layer[i]).AddSynapticConnection(connections[i]);
                connections[i].setWeight(tdConnWeights[i]);
            }
            newF2Neuron.setProtoTypeCluster(prototype);
            return(base.Count - 1);
        }
예제 #2
0
 public ConSelfART(int inputVectorLength, int categoryCountLimit, double rho, double alpha, double beta, bool cc)
 {
     this.CategoryCountLimit = categoryCountLimit;
     this.rho   = rho;
     this.alpha = alpha;
     this.beta  = beta;
     //F2 = new LayerF2();
     complementCoding = cc;
     if (cc)
     {
         i  = new double[inputVectorLength * 2];
         F1 = new LayerF1(inputVectorLength * 2);
     }
     else
     {
         i  = new double[inputVectorLength];
         F1 = new LayerF1(inputVectorLength);
     }
 }
예제 #3
0
 double beta;  // Learning Rate
 public ConSelfART(int inputVectorLength, double rho, double rhoInc, double alpha, double beta, bool cc)
 {
     this.rho     = rho;
     this.epsilon = rhoInc;
     this.alpha   = alpha;
     this.beta    = beta;
     //F2 = new LayerF2();
     complementCoding = cc;
     if (cc)
     {
         i  = new double[inputVectorLength * 2];
         F1 = new LayerF1(inputVectorLength * 2);
     }
     else
     {
         i  = new double[inputVectorLength];
         F1 = new LayerF1(inputVectorLength);
     }
 }