Implements a node in xpidea.neuro.net.son.SelfOrganizingNetwork
Inheritance: NeuroNode
Exemplo n.º 1
0
        /// <summary>
        ///     Overridden.Constructs network topology.
        /// </summary>
        protected override void CreateNetwork()
        {
            nodes        = new NeuroNode[NodesCount];
            linksCount   = NodesCount * rowsCount * columsCount;
            kohonenLayer = new NeuroNode[rowsCount, columsCount];
            links        = new NeuroLink[LinksCount];
            for (var i = 0; i < NodesCount; i++)
            {
                nodes[i] = new InputNode();
            }
            var curr = 0;

            for (var row = 0; row < rowsCount; row++)
            {
                for (var col = 0; col < columsCount; col++)
                {
                    kohonenLayer[row, col] = new SelfOrganizingNode(learningRate);
                    for (var i = 0; i < NodesCount; i++)
                    {
                        links[curr] = new SelfOrganizingLink();
                        nodes[i].LinkTo(kohonenLayer[row, col], links[curr]);
                        curr++;
                    }
                }
            }
        }
Exemplo n.º 2
0
 /// <summary>
 ///     Overridden.Constructs network topology.
 /// </summary>
 protected override void CreateNetwork()
 {
     nodes = new NeuroNode[NodesCount];
     linksCount = NodesCount*rowsCount*columsCount;
     kohonenLayer = new NeuroNode[rowsCount, columsCount];
     links = new NeuroLink[LinksCount];
     for (var i = 0; i < NodesCount; i++)
         nodes[i] = new InputNode();
     var curr = 0;
     for (var row = 0; row < rowsCount; row++)
         for (var col = 0; col < columsCount; col++)
         {
             kohonenLayer[row, col] = new SelfOrganizingNode(learningRate);
             for (var i = 0; i < NodesCount; i++)
             {
                 links[curr] = new SelfOrganizingLink();
                 nodes[i].LinkTo(kohonenLayer[row, col], links[curr]);
                 curr++;
             }
         }
 }