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

📄 sgnt_generating_online.m

📁 ISGNN是对SGNN(self-generated neural network)的一种改进,是一种在线学习的算法.
💻 M
字号:
function [Node] = sgnt_generating_online(y1,m)
% Generating A Self-Generating Neural Tree for traning a SGNN
% Copyright By Li Aiguo in 15/12/2004
%Input: y1: training set
%       m:  input vector dimision
%Ouput: node: a SGNT
%   node(j): (wj1,...,wjm);cj; Father_ptr; FirstChild_ptr; NextSibling_ptr  

%*****************************************************************************
% [nr,nc]= size(y1);
% if nr< nc  y1=y1'; end

%**************************************************************
alfa = 0;
% Generating a SGNT named node
%**************************************************************
% generating a root of the tree
 for k=1:1:m  node(1,k)= y1(1,k);   end
 node(1,m+1)= 1;
 node(1,m+2)= 0;
 node(1,m+3)= 0;
 node(1,m+4)= 0;
    
%****************************************************
% Generating the tree
[nr,nc]= size(y1);
 
 for i=2:1:nr 
      s = y1(i,1:m);
      node = sgnt_insert(node,s, alfa);
      % vertical placed well   
       node = sgnt_vhp_1(node);
      % HWP Purning  HWP(Horizontally Well Placed) d(n,np)<=d(n,ns)
      % node = sgnt_hwp_1(node);
        %merge
     node = sgnt_merge_1(node, alfa);
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    % HWP Purning  HWP(Horizontally Well Placed) d(n,np)<=d(n,ns)
    % node = sgnt_hwp_1(node);
   
end
 
Node = node; 

⌨️ 快捷键说明

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