Not able to train closed-loop for Narnet timeseries.
4 ビュー (過去 30 日間)
古いコメントを表示
I am not able to train narnet to make closed-loop.
Error is as follows:
- * Error using zeros
- * Requested 1x6166784512 (45.9GB) array exceeds maximum array size preference. Creation of arrays greater than this
- * limit may take a long time and cause MATLAB to become unresponsive. See array size limit or preference panel for
- * more information.
- *
- * Error in nnMex.perfsJEJJ>iJacobianFunctionForDirection (line 45)
- * TEMP = zeros(1,ceil(hints.tempSizeFJ/8)*8);
- *
- * Error in nnMex.perfsJEJJ (line 8)
- * [jacobian, TEMP] = iJacobianFunctionForDirection( direction, hints );
- *
- * Error in nnCalcLib/perfsJEJJ (line 388)
- * lib.calcMode.perfsJEJJ(calcNet,lib.calcData,lib.calcHints);
- *
- * Error in trainlm>initializeTraining (line 165)
- * [worker.perf,worker.vperf,worker.tperf,worker.je,worker.jj,worker.gradient] = calcLib.perfsJEJJ(calcNet);
- *
- * Error in nnet.train.trainNetwork>trainNetworkInMainThread (line 28)
- * worker = localFcns.initializeTraining(archNet,calcLib,calcNet,tr);
- *
- * Error in nnet.train.trainNetwork (line 16)
- * [archNet,tr] = trainNetworkInMainThread(archNet,rawData,calcLib,calcNet,tr,feedback,localFcns);
- *
- * Error in trainlm>train_network (line 156)
- * [archNet,tr] = nnet.train.trainNetwork(archNet,rawData,calcLib,calcNet,tr,localfunctions);
- *
- * Error in trainlm (line 55)
- * [out1,out2] = train_network(varargin{2:end});
- *
- * Error in network/train (line 369)
- * [net,tr] = feval(trainFcn,'apply',net,data,calcLib,calcNet,tr);
My Code is as follows:
T=tonndata(sdatat(1:end,1),false,false);
delay=[1:706];
hiddenlayersize=6;
trainFcn='trainlm';
net=narnet(delay,hiddenlayersize,'open',trainFcn);
net.divideFcn='divideblock';
net.trainParam.epochs = 3000;
net.divideParam.trainRatio = 70/100;
net.divideParam.valRatio = 15/100;
net.divideParam.testRatio = 15/100;
net.trainParam.min_grad=1e-7;
net.trainParam.max_fail=100;
net.performFcn = 'mse';
net.performParam.normalization = 'standard';
net.input.processFcns={'removeconstantrows','mapminmax'}
[Xso,Xio,Aio,Tso]=preparets(net,{},{},T);
rng('default')
net=train(net,Xso,Tso,Xio,Aio);
[Yso,Xfo,Afo]=net(Xso,Xio,Aio);
[netc,Xic,Aic]=closeloop(net,Xfo,Afo);
[Xc,Xic,Aic,Tc] = preparets(netc,{},{},T);
netc=train(netc,Xc,Tc,Xic,Aic);
This step causes the above error.
Please suggest where I am committing mistakes.
Thanks
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Sequence and Numeric Feature Data Workflows についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!