亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? nnd2n1.m

?? 神經(jīng)網(wǎng)絡(luò)設(shè)計書籍配套源碼(matlab平臺)
?? M
字號:
function nnd2n1(cmd,arg1,arg2,arg3)
%NND2N1 One-input neuron demonstration.
%
%	This demonstration requires either the MININNET functions
%	on the NND disk or the Neural Network Toolbox.

% First Version, 8-31-95.

%==================================================================

% CONSTANTS
me = 'nnd2n1';
max_t = 0.5;
w_max = 2;
p_max = 4;

% FLAGS
change_func = 0;

% DEFAULTS
if nargin == 0, cmd = ''; else cmd = lower(cmd); end

% FIND WINDOW IF IT EXISTS
fig = nnfgflag(me);
if length(get(fig,'children')) == 0, fig = 0; end
  
% GET WINDOW DATA IF IT EXISTS
if fig
  H = get(fig,'userdata');
  fig_axis = H(1);            % window axis
  desc_text = H(2);           % handle to first line of text sequence
  meters = H(3:6);            % input and output meters (axes)
  indicators = H(7:9);        % input and output indicators (patches)
  lines = H(10:12);           % lines in neuron function axis
  w_ptr = H(13);              % pointer to weight vector
  b_ptr = H(14);              % pointer to bias value
  f_ptr = H(15);              % pointer to transfer function
  p_ptr = H(16);              % pointer to input vector
  f_menu = H(17);             % transfer function menu
  f_text = H(18);             % neuron heading text
  cross = H(19);              % origon cross lines
end

%==================================================================
% Activate the window.
%
% ME() or ME('')
%==================================================================

if strcmp(cmd,'')
  if fig
    figure(fig)
    set(fig,'visible','on')
  else
    feval(me,'init')
  end

%==================================================================
% Close the window.
%
% ME() or ME('')
%==================================================================

elseif strcmp(cmd,'close') & (fig)
  delete(fig)

%==================================================================
% Initialize the window.
%
% ME('init')
%==================================================================

elseif strcmp(cmd,'init') & (~fig)

  % CHECK FOR TRANSFER FUNCTIONS
  if ~nnfexist(me), return, end

  % CONSTANTS
  w = 1;
  b = 0;
  p = 0;
  f = 'purelin';
  n = w*p+b;
  a = feval(f,w*p,b);
  title_str = 'Neuron Model Demonstration';
  chapter_str = 'Chapter 2';
  a_lim = [-2 2];
  P = [-p_max:0.1:p_max];
  A = feval(f,w*P,b);
  ind = find(A >= -p_max & A <= p_max);
  P = P(ind);
  A = A(ind);

  % NEW DEMO FIGURE
  fig = nndemof2(me,'DESIGN','One-Input Neuron','','Chapter 2');
  set(fig, ...
    'windowbuttondownfcn',nncallbk(me,'down'), ...
    'BackingStore','off',...
    'nextplot','add');
  H = get(fig,'userdata');
  fig_axis = H(1);
  desc_text = H(2);

  % ICON
  nndicon(2,458,363,'shadow')

  % NEURON DIAGRAM
  x = 60;
  y = 340;
  plot(x+[0 100],y-[50 50],...
   'linewidth',4,...
   'color',nnred);
  plot(x+[100 100],y-[49 91],...
   'linewidth',4,...
   'color',nnred);
  nndicon(100,x+100,y-50)
  plot(x+[125 185],y-[50 50],...
   'linewidth',4,...
   'color',nnred);
  plot(x+[200 250],y-[50 50],...
   'linewidth',4,...
   'color',nnred);
  plot(x+[240 250 240],y-[40 50 60],...
   'linewidth',4,...
   'color',nnred);
  nndicon(101,x+200,y-50)
  fill(x+[90 110 110 90],y-[115 115 95 95],nnltyell,...
    'edgecolor',nndkblue)
  text(x+101,y-106,'1',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center');

  text(x-10,y-50,'p',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center',...
    'erasemode','none');
  text(x+40,y-40,'w',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center',...
    'erasemode','none');
  text(x+115,y-85,'b',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center',...
    'erasemode','none');
  text(x+265,y-50,'a',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center',...
    'erasemode','none');

  deg = pi/180;
  angle = [0:5:90]*deg;
  xc = cos(angle)*10;
  yc = sin(angle)*10;

  plot(x-20-xc,y-20+yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+[-20 0],y-[10 10],...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+xc,y-20+yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x-20-xc,y-115-yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+[-20 0],y-[125 125],...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+xc,y-115-yc,...
   'linewidth',3,...
   'color',nndkblue);
  text(x-10,y+5,'Input',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center');

  plot(x+30-xc,y-20+yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+[30 280],y-[10 10],...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+280+xc,y-20+yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+30-xc,y-115-yc,...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+[30 280],y-[125 125],...
   'linewidth',3,...
   'color',nndkblue);
  plot(x+280+xc,y-115-yc,...
   'linewidth',3,...
   'color',nndkblue);
  f_text = text(x+155,y+5,'Linear Neuron: a = purelin(w*p+b)',...
    'color',nndkblue,...
    'fontweight','bold',...
    'horiz','center',...
    'erasemode','none');

  text(x+35,y-100,'F:',...
    'fontname','helvetica',...
    'fontweight','bold',...
    'color',nndkblue,...
    'horiz','center',...
    'fontsize',12)

  % PARAMETERS
  y = 160;
  x = 40;
  w_axis = nnsfo('a2','w','','');

  set(w_axis, ...
    'units','points',...
    'position',[x y 70 20],...
    'color',nnmdgray,...
    'ylim',[-0.3 1.3],...
    'ytick',[],...
    'xlim',[-1.3 1.3]*w_max,...
    'xtick',[-1 -0.5 0 0.5 1]*w_max,...
    'xticklabels',str2mat(num2str(-w_max),'','0','',num2str(w_max)))

  w_ind = fill([0 0.2 -0.2]*w_max+w,[0 1 1],nnred,...
    'edgecolor',nndkblue,...
    'erasemode','none');

  b_axis = nnsfo('a2','b','','');

  set(b_axis, ...
    'units','points',...
    'position',[x y-65 70 20],...
    'color',nnmdgray,...
    'ylim',[-0.3 1.3],...
    'ytick',[],...
    'xlim',[-1.3 1.3]*w_max,...
    'xtick',[-1 -0.5 0 0.5 1]*w_max,...
    'xticklabels',str2mat(num2str(-w_max),'','0','',num2str(w_max)))

  b_ind = fill([0 0.2 -0.2]*w_max+b,[0 1 1],nnred,...
    'edgecolor',nndkblue,...
    'erasemode','none');
  f_menu = uicontrol(...
    'units','points',...
    'position',[x y-130, 80 20],...
    'style','popupmenu',...
    'string','Hardlim|Hardlims|Purelin|Satlin|Satlins|Logsig|Tansig',...
    'background',nnmdgray,...
    'callback',[me '(''function'')'],...
    'value',3);

  % NEURON FUNCTION
  y = 40;
  x = 200;
  a_axis = nnsfo('a2','','p','a');
  set(get(a_axis,'xlabel'),...
    'fontsize',12)
  set(get(a_axis,'ylabel'),...
    'fontsize',12)
  set(a_axis, ...
    'units','points',...
    'position',[x y 140 140],...
    'color',nnltyell,...
    'xlim',[-1.05 1.05]*p_max,...
    'xtick',[-4 -2 0 2 4],...
    'ylim',[-1.05 1.05]*p_max,...
    'ytick',[-4 -2 0 2 4])
  cross = plot([-p_max p_max NaN 0 0],[0 0 NaN -p_max p_max],':',...
    'color',nndkblue,...
    'erasemode','none');
  p_line = plot([p p],[-p_max p_max],'--',...
    'color',nnred,...
    'erasemode','none');
  a = feval(f,w*p,b);
  a_line = line([-p_max p],[a a],...
    'color',nnred,...
    'erasemode','none');
  A_line = line(P,A,...
    'color',nndkblue,...
    'erasemode','none',...
    'linewidth',2);
  p_axis = nnsfo('a2','','','');
  set(p_axis, ...
    'units','points',...
    'position',[x y+140 140 15],...
    'color',nnltyell,...
    'xlim',[-1.05 1.05]*p_max,...
    'xtick',[-4 -2 0 2 4],...
    'ylim',[-0.1 1.1],...
    'ytick',[])
  axis('off')
  p_ind = fill([0 0.125 -0.125]*p_max+p,[0 1 1],nnred,...
    'edgecolor',nndkblue,...
    'erasemode','none');

  % BUTTONS
  drawnow % Let everything else appear before buttons 
  uicontrol(...
    'units','points',...
    'position',[400 110 60 20],...
    'string','Contents',...
    'callback','nndtoc')
  uicontrol(...
    'units','points',...
    'position',[400 75 60 20],...
    'string','Close',...
    'callback',[me '(''close'')'])

  % DATA POINTERS
  meters = [w_axis b_axis p_axis a_axis];
  indicators = [w_ind b_ind p_ind];
  lines = [p_line a_line A_line];
  w_ptr = uicontrol('visible','off'); set(w_ptr,'userdata',w);
  b_ptr = uicontrol('visible','off'); set(b_ptr,'userdata',b);
  f_ptr = uicontrol('visible','off'); set(f_ptr,'userdata',f);
  p_ptr = uicontrol('visible','off'); set(p_ptr,'userdata',p);

  % SAVE WINDOW DATA AND LOCK
  H = [fig_axis desc_text meters indicators lines w_ptr b_ptr f_ptr p_ptr ...
    f_menu f_text cross];
  set(fig,'userdata',H,'nextplot','new')

  % INSTRUCTION TEXT
  feval(me,'instr');

  % LOCK WINDOW
  set(fig,...
   'nextplot','new',...
   'color',nnltgray);

  nnchkfs;

%==================================================================
% Display the instructions.
%
% ME('instr')
%==================================================================

elseif strcmp(cmd,'instr') & (fig)
  nnsettxt(desc_text,...
    'Alter the weight, bias',...
    'and input by dragging',...
    'the triangular shaped',...
    'indicators.',...
	'',...
	'Pick the transfer',...
	'function with the',...
	'F menu.',...
    '',...
    'Watch the change to',...
    'the neuron function',...
    'and its output.')
    
%==================================================================
% Respond to mouse down.
%
% ME('down')
%==================================================================

elseif strcmp(cmd,'down') & (fig) & (nargin == 1)

  q = 0;
  for i=1:3
    pt = get(meters(i),'currentpoint');
    x = pt(1);
    y = pt(3);

    if (i <= 2)
      if (x >= -1.3*w_max) & (x <= 1.3*w_max) & (y >= 0) & (y <= 1)
        q = i;
        z_max = w_max;
        z = x;
        hide_color = nnmdgray;
        width = 0.2;
        break;
      end
    else
      if (x >= -1.1*p_max) & (x <= 1.1*p_max) & (y >= 0) & (y <= 1)
        q = i;
        z_max = p_max;
        z = x;
        hide_color = nnltgray;
        width = 0.125;
        break;
      end
    end
  end

  if (q)
    set(fig,'pointer','crosshair')
    z = min(z_max,max(-z_max,z));
    set(indicators(q),...
      'facecolor',hide_color,...
      'edgecolor',hide_color)
    set(indicators(q),...
      'xdata',[0 1 -1]*width*z_max+z,...
      'facecolor',nnred,...
      'edgecolor',nndkblue)
    set(fig,'WindowButtonMotionFcn',[me '(''down'')']);
    set(fig,'WindowButtonUpFcn',[me '(''up'')']);

    % ALTER VARIABLES
    if (q == 1)
      set(w_ptr,'userdata',z);
      change_func = 1;
    elseif (q == 2)
      set(b_ptr,'userdata',z);
      change_func = 1;
    else
      set(p_ptr,'userdata',z);
    end
  cmd = 'update';
  else
    set(fig,'pointer','arrow')
  end

%==================================================================
% Respond to mouse up.
%
% ME('up')
%==================================================================

elseif strcmp(cmd,'up') & (fig) & (nargin == 1)

  set(fig,...
    'WindowButtonMotionFcn','',...
    'pointer','arrow')

%==================================================================
% Respond to function menu.
%
% ME('function')
%==================================================================

elseif strcmp(cmd,'function') & (fig) & (nargin == 1)

  v = get(f_menu,'value');

  if     v == 1, f = 'hardlim';  new_text = 'Hard Limit Neuron';
  elseif v == 2, f = 'hardlims'; new_text = 'Sym. Hard Limit Neuron';
  elseif v == 3, f = 'purelin';  new_text = 'Linear Neuron';
  elseif v == 4, f = 'satlin';   new_text = 'Saturating Linear Neuron';
  elseif v == 5, f = 'satlins';  new_text = 'Sym. Sat. Linear Neuron';
  elseif v == 6, f = 'logsig';   new_text = 'Log Sigmoid Neuron';
  elseif v == 7, f = 'tansig';   new_text = 'Tan Sigmoid Neuron';
  elseif v == 8, f = 'radbas';   new_text = 'Log Sigmoid Neuron';
  end

  new_text = [new_text ': a = ' f '(w*p+b)'];
  set(f_text,...
    'color',nnltgray);
  set(f_text,...
    'string',new_text,...
    'color',nndkblue);
  set(f_ptr,'userdata',f);
  change_func = 1;
  cmd = 'update';

%==================================================================
end

%==================================================================
% Respond to request to update displays.
%
% ME('update')
%==================================================================

if strcmp(cmd,'update') & (fig)
  
  % GET DATA
  w = get(w_ptr,'userdata');
  b = get(b_ptr,'userdata');
  f = get(f_ptr,'userdata');
  p = get(p_ptr,'userdata');

  % UPDATE OUTPUT
  n = w*p+b;
  if strcmp(f,'satlin')
    a = (~((n < 0) | (n > 1))).*n + (n > 1);
  elseif strcmp(f,'satlins')
    a = (~((n < -1) | (n > 1))).*n + (n > 1) - (n < -1);
  else
    a = feval(f,n);
  end

  % HIDE LINES
  set(lines(1:2),...
    'color',nnltyell)

  % HIDE & RECALCULATE FUNCTION IF ALTERED
  if (change_func)
    set(lines(3),...
      'color',nnltyell)
    P = [-p_max:0.1:p_max];
    A = feval(f,w*P,b);
    ind = find(A >= -p_max & A <= p_max);
    P = P(ind);
    A = A(ind);
    set(lines(3),...
      'xdata',P,...
      'ydata',A)
  end

  % REFRESH NEURON FUNCTION & CROSS LINE
  set(lines(3),...
    'color',nndkblue)
  set(cross,...
    'color',nndkblue)

  % SHOW NEW LINES
  set(lines(1),...
    'xdata',[p p],...
    'color',nnred)
  if (a >= -p_max) & (a <= p_max)
    set(lines(2),...
      'xdata',[-p_max p],...
      'ydata',[a a],...
      'color',nnred)
    set(lines(2),...
      'visible','on')
  else
    set(lines(2),...
      'ydata',[a a],...
      'visible','off')
  end
end

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色婷婷精品大在线视频| 欧美三级一区二区| 亚洲欧美激情视频在线观看一区二区三区 | 美女视频黄 久久| 午夜久久久影院| 日本美女视频一区二区| 日韩电影在线一区| 奇米综合一区二区三区精品视频| 亚洲一区二区三区四区在线观看 | 丰满少妇在线播放bd日韩电影| 国产河南妇女毛片精品久久久| 精品一区二区三区在线播放| 国内成人精品2018免费看| 国产精品影音先锋| 国模大尺度一区二区三区| 国产乱码字幕精品高清av| 粉嫩av一区二区三区在线播放| 国产成人三级在线观看| 91婷婷韩国欧美一区二区| 在线观看亚洲a| 日韩精品中文字幕一区 | 99re6这里只有精品视频在线观看| 成人性生交大合| 日本精品一区二区三区四区的功能| 在线亚洲高清视频| 亚洲精品在线观| 亚洲免费观看高清在线观看| 日韩国产在线观看一区| 国产成人免费9x9x人网站视频| 色妞www精品视频| 制服丝袜国产精品| 国产精品三级电影| 午夜视频在线观看一区二区| 国产福利一区二区| 欧美日韩免费观看一区二区三区| 26uuu国产一区二区三区| 亚洲欧洲av另类| 久久99精品久久久久久| 色综合久久久久综合99| 337p粉嫩大胆噜噜噜噜噜91av| 亚洲精品高清在线| 国产经典欧美精品| 欧美一区二区在线不卡| 中文字幕中文字幕在线一区 | 亚洲国产精品一区二区久久| 激情亚洲综合在线| 欧美影院一区二区| 中文字幕成人在线观看| 日韩成人av影视| 日本韩国欧美在线| 国产日韩欧美精品一区| 日本女人一区二区三区| 色综合中文字幕国产| 日韩一区二区三区免费看 | 有坂深雪av一区二区精品| 成人午夜激情影院| 精品久久一区二区三区| 亚洲午夜一二三区视频| 94-欧美-setu| 国产精品麻豆一区二区| 国产一二精品视频| 精品乱码亚洲一区二区不卡| 日韩国产精品久久| 欧美伦理视频网站| 亚洲成人激情av| 欧美少妇一区二区| 亚洲人成网站在线| 91久久国产最好的精华液| 亚洲女子a中天字幕| www.亚洲精品| 亚洲人123区| 一本色道综合亚洲| 亚洲三级在线播放| 色综合天天视频在线观看| 国产精品久久免费看| 大胆亚洲人体视频| 日韩一区日韩二区| 91欧美一区二区| 亚洲四区在线观看| 91在线国产福利| 一区二区三区产品免费精品久久75| 91在线视频观看| 一区二区三区久久| 欧美日韩三级一区| 精品一区二区三区的国产在线播放 | 福利电影一区二区| 国产精品久久久久婷婷二区次| 99精品欧美一区二区三区综合在线| 中文在线资源观看网站视频免费不卡 | 欧美久久久久久久久久| 日韩高清不卡在线| 欧美精品一区二区三区四区| 国产精品一线二线三线| 国产精品久久久久aaaa樱花| 91福利区一区二区三区| 日本不卡不码高清免费观看| 精品久久久久久久一区二区蜜臀| 国产成人在线视频免费播放| 亚洲日本在线天堂| 欧美精品免费视频| 国产精品一区一区| 亚洲日本乱码在线观看| 欧美久久一区二区| 国产成人免费av在线| 亚洲午夜激情av| 久久一区二区视频| 在线这里只有精品| 韩国v欧美v日本v亚洲v| 亚洲激情图片qvod| 久久久国际精品| 欧美亚洲日本国产| 国产精品99久久久久久久vr| 夜色激情一区二区| 久久久久国产精品免费免费搜索| 色88888久久久久久影院野外| 狠狠色丁香婷婷综合| 亚洲午夜精品在线| 国产精品国产三级国产有无不卡 | 国产乱人伦偷精品视频不卡| 亚洲五月六月丁香激情| 欧美mv日韩mv国产网站app| www.亚洲精品| 国产高清不卡一区| 蜜桃91丨九色丨蝌蚪91桃色| 一级中文字幕一区二区| 欧美—级在线免费片| 91精品免费在线观看| 色噜噜夜夜夜综合网| 高清国产一区二区三区| 国内不卡的二区三区中文字幕 | 国产精品初高中害羞小美女文| 欧美一级艳片视频免费观看| av一区二区三区在线| 国产麻豆成人精品| 欧美aa在线视频| 亚洲成人精品一区二区| 亚洲自拍偷拍av| 亚洲精品免费在线| 亚洲欧洲99久久| 国产精品美女久久久久久| 久久久久久久一区| 久久九九全国免费| 久久久久久久久久看片| 精品999在线播放| 精品少妇一区二区三区视频免付费| 欧美日韩精品高清| 欧美三级电影一区| 91精品欧美久久久久久动漫| 欧美日韩国产首页在线观看| 欧美三级韩国三级日本一级| 欧洲av在线精品| 欧美色窝79yyyycom| 在线免费精品视频| 欧美日韩卡一卡二| 91精品国产乱码| 欧美一二三区精品| 精品久久久久久最新网址| 亚洲精品在线观看网站| 国产日韩精品一区二区三区| 国产日产欧美一区| 国产精品天干天干在观线| 亚洲国产精品黑人久久久| 中文字幕中文乱码欧美一区二区| 国产欧美1区2区3区| 国产精品乱人伦| 亚洲男同性视频| 日韩经典一区二区| 国产一区二区免费在线| 成人禁用看黄a在线| 91美女福利视频| 欧美一卡二卡在线观看| 久久精品在线免费观看| 亚洲男人都懂的| 日本系列欧美系列| 高清shemale亚洲人妖| 一本大道久久精品懂色aⅴ| 欧美日韩视频专区在线播放| 精品久久免费看| 成人免费一区二区三区视频| 亚洲一区二区黄色| 精品一区二区国语对白| jiyouzz国产精品久久| 欧美无砖专区一中文字| 久久久久久久久久久99999| 一区二区三区在线视频观看| 日韩av一二三| 成人av网址在线| 91精品国产色综合久久不卡蜜臀| 久久久久久久久免费| 亚洲风情在线资源站| 国产91富婆露脸刺激对白| 欧美区一区二区三区| 国产女同性恋一区二区| 视频一区二区不卡| 国产91精品露脸国语对白| 欧美一卡二卡在线| 一区二区三区美女| 国产成人精品亚洲777人妖| 7777精品伊人久久久大香线蕉经典版下载| 久久综合视频网|