Beispiel #1
0
        public SOMColors()
        {
            InitializeComponent();

            network = CreateNetwork();
            gaussian = new NeighborhoodRBF(RBFEnum.Gaussian, WIDTH, HEIGHT);
            train = new BasicTrainSOM(network, 0.01, null, gaussian);

            train.ForceWinner = false;
            samples = AIFH.Alloc2D<double>(15, 3);
            
            for (int i = 0; i < 15; i++)
            {
                samples[i][0] = rnd.NextDouble(-1, 1);
                samples[i][1] = rnd.NextDouble(-1, 1);
                samples[i][2] = rnd.NextDouble(-1, 1);
            }

            train.SetAutoDecay(100, 0.8, 0.003, 30, 5);
        }
Beispiel #2
0
 /// <summary>
 ///     Construct a BestMatchingUnit class.  The training class must be provided.
 /// </summary>
 /// <param name="som">The SOM to evaluate.</param>
 public BestMatchingUnit(SelfOrganizingMap som)
 {
     _som = som;
 }
Beispiel #3
0
 /// <summary>
 ///     Construct a BestMatchingUnit class.  The training class must be provided.
 /// </summary>
 /// <param name="som">The SOM to evaluate.</param>
 public BestMatchingUnit(SelfOrganizingMap som)
 {
     _som = som;
 }
Beispiel #4
0
 private SelfOrganizingMap CreateNetwork()
 {
     var result = new SelfOrganizingMap(3, WIDTH*HEIGHT);
     result.Reset();
     return result;
 }