2

I've come across two types of neural networks to predict, both from Matlab, the closed structure and the net that removes one delay to find new data.

From Matlab's app generated scripts we see:

% Closed Loop Network % Use this network to do multi-step prediction. % The function CLOSELOOP replaces the feedback input with a direct % connection from the output layer.

netc = closeloop(net);
netc.name = [net.name ' - Closed Loop'];
view(netc)
[xc,xic,aic,tc] = preparets(netc,{},{},T);
yc = netc(xc,xic,aic);
closedLoopPerformance = perform(net,tc,yc)

% Step-Ahead Prediction Network % For some applications it helps to get the prediction a timestep early. % The original network returns predicted y(t+1) at the same time it is % given y(t+1). For some applications such as decision making, it would % help to have predicted y(t+1) once y(t) is available, but before the % actual y(t+1) occurs. The network can be made to return its output a % timestep early by removing one delay so that its minimal tap delay is now % 0 instead of 1. The new network returns the same outputs as the original % network, but outputs are shifted left one timestep.

nets = removedelay(net);
nets.name = [net.name ' - Predict One Step Ahead'];
view(nets)
[xs,xis,ais,ts] = preparets(nets,{},{},T);
ys = nets(xs,xis,ais);
stepAheadPerformance = perform(nets,ts,ys)

My question is: What is the real difference between them?

Can one uses them equivalently? If yes, why? I mean, even tho the structure or how they are equipped, could be very very different, e.g. one is apple, the other is grape?

As far as I understand both can return new data if one codes them for that. For example, taking the closed net, one can predict 10 new values. Taking the net that removes one delay, one can predict one new value, but if one does this recursively 9 times, one can get the new 10 data. Is there a problem in using this last net in that way?

On another side, running both codes, as they are now (this changes depending on the code one works on), yields very different performances. Why?

Update:

I've checked this page https://www.mathworks.com/matlabcentral/answers/297187-neural-network-closed-loop-vs-open-loop, and in the answer by Greg Heath, we see

[...]

OPENLOOP: The desired output, AKA the delayed target, is used as an additional input. The OL net will produce output for the common time extent of the input and target. CLOSELOOP: The delayed target input is replaced by a direct delayed output connection. The CL net will produce output for the time extent of the input.

[...]

"The desired output, AKA the delayed target, is used as an additional input." how is this?

"The OL net will produce output for the common time extent of the input and target." and this?

"The CL net will produce output for the time extent of the input." What does this mean?

1 Answers1

0
Closed Loop Network Step-Ahead Prediction Network
The function CLOSELOOP replaces the feedback input with a direct connection from the output layer. Step-Ahead Prediction Network also known as removedelay function helps to remove delay to neural network’s response
In Closed loop networks, its own predictions become the feedback inputs. targets with a delay were used as feedback input
Network used to do multi-step prediction Network used to predict one step ahead
Highly helpful to turn the network into parallel configuration Can't be used for parallel configuration
Output is not shifted one timestep the output is shifted one timestep.
Closed loop network continue to predict when external feedback is missing, by using internal feedback Open-loop and Remove-delay use external feedback
Real time Configuration Not real time configuration
Closed loop network will produce output for the time extent of the input. will produce output for the common time extent of the input and target.
Closed Loop Network Step-Ahead Prediction Network

Open-Loop Network In open-loop networks, targets were used as feedback inputs. Open loops are primarily used when future outputs are not known. Below is how open loop network looks like Note:

The typical workflow is to fully create the network in open loop, and only when it has been trained (which includes validation and testing steps) it is transformed to closed loop for multistep-ahead prediction

Open loop network

UPDATED Response to newly added questions

"The desired output, AKA the delayed target, is used as an additional input." how is this?

This is with reference to the Step-Ahead prediction network. Here, the delayed target is used as an additional input. Kindly refer to diagram in point #9. when the target is y(t+1) the additional input is the delayed target, i.e., y(t). Whereas in open-loop target is used as additional input this is the main difference between OL and step ahead prediction.

"The OL net will produce output for the common time extent of the input and target." and this?

As you can see, the open-loop network will produce output y(t) as long as open-loop has two inputs x(t)and the targety(t)` for a certain time

"The CL net will produce output for the time extent of the input." What does this mean?

In closed loop based on the input x(t) the output y(t) will be produced for a certain time

Reference Link:

Archana David
  • 277
  • 2
  • 9
  • 3
    Some of the text here appears to have been copy-pasted from an external source, without attribution -- e.g., "continue to predict when external feedback is missing, by using internal feedback" appears to have been copied from https://www.mathworks.com/help/deeplearning/ug/multistep-neural-network-prediction.html or another source. The images also appear to have been copied, e.g., from the same article, and https://www.mathworks.com/help/deeplearning/gs/neural-network-time-series-prediction-and-modeling.html, and so on. – D.W. Dec 27 '21 at 02:25
  • 3
    [Plagiarism](https://ai.stackexchange.com/help/referencing) is [not cool](https://meta.stackexchange.com/questions/83955/plagiarism-should-be-addressed-specifically-in-the-faq/134715#134715). – D.W. Dec 27 '21 at 02:26