Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

openloop

Convert neural network closed-loop feedback to open loop

Syntax

net = openloop(net)
[net,xi,ai] = openloop(net,xi,ai)

Description

net = openloop(net) takes a neural network and opens any closed-loop feedback. For each feedback output i whose property net.outputs{i}.feedbackMode is 'closed', it replaces its associated feedback layer weights with a new input and input weight connections. The net.outputs{i}.feedbackMode property is set to 'open', and the net.outputs{i}.feedbackInput property is set to the index of the new input. Finally, the value of net.outputs{i}.feedbackDelays is subtracted from the delays of the feedback input weights (i.e., to the delays values of the replaced layer weights).

[net,xi,ai] = openloop(net,xi,ai) converts a closed-loop network and its current input delay states xi and layer delay states ai to open-loop form.

Examples

Convert NARX Network to Open-Loop Form

Here a NARX network is designed in open-loop form and then converted to closed-loop form, then converted back.

[X,T] = simplenarx_dataset;
net = narxnet(1:2,1:2,10);
[Xs,Xi,Ai,Ts] = preparets(net,X,{},T);
net = train(net,Xs,Ts,Xi,Ai);
view(net)
Yopen = net(Xs,Xi,Ai)
net = closeloop(net)
view(net)
[Xs,Xi,Ai,Ts] = preparets(net,X,{},T);
Yclosed = net(Xs,Xi,Ai);
net = openloop(net)
view(net)
[Xs,Xi,Ai,Ts] = preparets(net,X,{},T);
Yopen = net(Xs,Xi,Ai)

Convert Delay States

For examples on using closeloop and openloop to implement multistep prediction, see narxnet and narnet.

Introduced in R2010b

Was this topic helpful?