private void Window_Loaded(object sender, RoutedEventArgs e)
		{
			ira = IRINA_NN.Import(@"mnist.nn");
			reader = new MNISTDataReader.ImageDataReader(@"D:\NeuralNetworks\DataSets\MNIST\t10k-images.idx3-ubyte");
			lablesReader = new MNISTDataReader.LabelDataReader(@"D:\NeuralNetworks\DataSets\MNIST\t10k-labels.idx1-ubyte");

			Predict();

			//IrisDataReader irisDataReader = new IrisDataReader(@"D:\NeuralNetworks\DataSets\Iris Plants Database\bezdekIris.data");

			//var rand = new Random();

			//while(true)
			//{
			//	irisDataReader.Read(rand.Next(0, 150));
			//}

			//calcError();
		}
        void drawMNIST()
        {
            var ira = new IRINA_NN(new int[] { 784, 200, 10 }, 0.2);

            var imageReader = new MNISTDataReader.ImageDataReader(@"D:\NeuralNetworks\DataSets\MNIST\train-images.idx3-ubyte");

            var labelReader = new MNISTDataReader.LabelDataReader(@"D:\NeuralNetworks\DataSets\MNIST\train-labels.idx1-ubyte");

            var itemsCount = imageReader.ItemsCount;
            var random     = new Random();

            Stopwatch stopwatch = new Stopwatch();

            stopwatch.Start();

            for (int epoch = 0; epoch < count; ++epoch)
            {
                //var errors = new List<double>();

                for (int sample = 0; sample < samplesInBatch; ++sample)
                {
                    var realIndex = random.Next(0, itemsCount);
                    var input     = prepareInput(imageReader.Read(realIndex));
                    var label     = labelReader.Read(realIndex);
                    var target    = prepareTarget(label);

                    ira.Train(input, target);

                    //var predicted = ira.Predict(input);
                    //errors.Add(0.99 - predicted[label]);
                }

                //SeriesCollection[0].Values.Add(errors.Average());
            }

            stopwatch.Stop();

            IRINA_NN.Export(ira, @"mnist.nn");

            MessageBox.Show($"Complete { count } epochs, { samplesInBatch } samples per one. Estimated time: { stopwatch.ElapsedMilliseconds }ms");
        }