예제 #1
0
파일: Form1.cs 프로젝트: LongHK27/NNets
        public Form1()
        {
            InitializeComponent();

            string path = Directory.GetCurrentDirectory().ToString() + "\\data\\";

            NeuronNets.Init(path);
        }
예제 #2
0
파일: Form1.cs 프로젝트: LongHK27/NNets
        private void button3_Click(object sender, EventArgs e)
        {
            var dialog = new OpenFileDialog();

            if (dialog.ShowDialog() == DialogResult.OK)
            {
                using (var image = (new Image <Gray, byte>(dialog.FileName)).ThresholdBinaryInv(new Gray(180), new Gray(255)))
                {
                    CvInvoke.Resize(image, image, new Size(28, 28));

                    pictureBox1.Image = image.Bitmap;
                    pictureBox1.Refresh();

                    label3.Text = NeuronNets.Active(image).ToString();
                    label3.Refresh();
                }
            }
        }
예제 #3
0
파일: Form1.cs 프로젝트: LongHK27/NNets
 private void button2_Click(object sender, EventArgs e)
 {
     NeuronNets.Training();
 }