⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 unit1.h

📁 小弟撰寫的類神經網路backpropagataion,可以train如xor等互斥問題,使用bcb所完成,因為開發介面較為便利, 大部分使用類別的方法撰寫,所以若有興趣移植到vc的朋友,應該也不會有
💻 H
字号:
//---------------------------------------------------------------------------

#ifndef Unit1H
#define Unit1H
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include<stdlib.h>
//---------------------------------------------------------------------------
class TForm1 : public TForm
{
__published:	// IDE-managed Components
        TGroupBox *GroupBox1;
        TListBox *ListBox1;
        TButton *Button1;
        TListBox *ListBox2;
        TListBox *ListBox3;
        TGroupBox *GroupBox2;
        TComboBox *ComboBox2;
        TGroupBox *GroupBox3;
        TListBox *ListBox4;
        TButton *Button2;
        TEdit *Edit1;
        TEdit *Edit2;
        TEdit *Edit3;
        TEdit *Edit4;
        TLabel *Label1;
        TLabel *Label2;
        TLabel *Label3;
        TLabel *Label4;
        TLabel *Label5;
        TLabel *Label6;
        TLabel *Label7;
        TComboBox *ComboBox3;
        TComboBox *ComboBox1;
        TEdit *Edit5;
        TEdit *Edit6;
        TLabel *Input_Vaule;
        TLabel *Output_Vaule;
        TButton *Button3;
        TListBox *ListBox5;
        void __fastcall Button1Click(TObject *Sender);
        void __fastcall Button2Click(TObject *Sender);
        void __fastcall Button3Click(TObject *Sender);
        void __fastcall FormCreate(TObject *Sender);
private:	// User declarations
public:		// User declarations
        __fastcall TForm1(TComponent* Owner);
};
class nn_train
{
public:
  double weight_num[100][100];
  double delta_weight[100][100];
  double input_vaule[100][100];
  double output_vaule[100][100];
  double a[100],ta[100];
  double n_error[100];
  int nn_input,nn_output,input_index,output_index,count;
  int nn_testin,nn_testout,test_indexin,test_indexout;
  double s_delta[100];
  double error,rate;
  int hidden;
  void initial(void);
  void initial_ai(int num);
  void reflash_weight(int num);
};
//---------------------------------------------------------------------------
extern PACKAGE TForm1 *Form1;
//---------------------------------------------------------------------------
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -