MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   MATLAB论坛 (https://www.labfans.com/bbs/forumdisplay.php?f=6)
-   -   [求助]请大侠帮忙找出错误…… (https://www.labfans.com/bbs/showthread.php?t=5556)

cquc_2002 2008-11-30 10:09

[求助]请大侠帮忙找出错误……
 
初学神经网络,做了一个简单的BP网络,却无法运行 ,又找不到原因 请大家帮忙……
p=[0.667 1.5 0.0086 1;0.667 1.5 0.0086 2;0.667 1.5 0.0086 3;0.667 2 0.0115 1;0.667 2 0.0115 2;0.667 2 0.0115 3;0.667 2.5 0.0143 1;0.667 2.5 0.0143 2;0.667 2.5 0.0143 3;0.667 2 0.0230 1;0.667 2 0.0230 2;0.667 2 0.0230 3;0.667 2 0.0345 1;0.667 2 0.0345 2;0.667 2 0.0345 3;0.667 2 0.0460 1;0.667 2 0.0460 2;0.667 2 0.0460 3;1 2 0.0115 1;1 2 0.0115 2;1 2 0.0115 3;0.8 2 0.0115 1;0.8 2 0.0115 2;0.8 2 0.0115 3;0.574 2 0.0115 1;0.574 2 0.0115 2;0.574 2 0.0115 3]
t=[0.413;0.421;0.089;0.683;0.692;0.102;0.954;1.028;0.143;1.886;1.789;0.279;3.613;3.615;0.529;4.936;5.096;0.776;1.371;1.333;0.109;0.905;0.894;0.107;0.437;0.481;0.101]
net=newff(minmax(p),[4,1],{'tansig','purelin'},'traingda');
net.trainParam.show = 50;
net.trainParam.lr =0.05;
net.trainParam.lr_inc =1.05;
net.trainParam.epochs =300;
net.trainParam.goal=1e-5;
[net,tr]=train(net,p,t);

cixiang 2008-11-30 21:29

回复: [求助]请大侠帮忙找出错误……
 
p和t的列数不一致吧!~

guofeng0108 2008-12-01 02:34

回复: [求助]请大侠帮忙找出错误……
 
把t换为行向量就好了!!!!!!!

sbyong 2008-12-04 14:26

回复: [求助]@急!求助各位高手!BP神经网络训练问题@
 
系统提示的错误是什么?
自己去猜错误多麻烦!

sbyong 2008-12-04 14:27

回复: [求助]@急!求助各位高手!BP神经网络训练问题@
 
你的p和t需要转置

未注册 2008-12-08 15:00

回复: [求助]请大侠帮忙找出错误……
 
en 搞定了
谢谢诸位

sgchargers 2009-01-05 14:32

Shuoguan4
 
[url=http://www.chargerschina.com/]towards the topic above[/url] , and I am going to go ahead on your way.


所有时间均为北京时间。现在的时间是 03:11

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.