Clear Filters
Clear Filters

Dimensions of T and Y in a customized regression layer

1 view (last 30 days)
I did not understand what are the dimensions of T and Y in a customized regression layer (reference : Looking at my specific case, I have a training dataset with 28x70000 observed input sequences and 1x70000 observed target values. In my case, I am trying to predict the full target sequence. This custom regression layer is the last layer of the network. Before this custom regression layer, I have a fullyConnectedLayer that outputs a scalar (I don't know if this information could be useful in some way). Anyway, what do T (target) and Y (observations) represent? What are their dimensions in my specific case? For instance, I would have expected T to have a size of 1x70000, but I am sure this is not true because I also tried to transpose T and it gave an error, hence it can be probably a multidimensional Matrix Thank you very much!

Answers (1)

Cris LaPierre
Cris LaPierre on 4 Jan 2024
Moved: Cris LaPierre on 4 Jan 2024
Comments in the code example you link to provide the following information
% Inputs:
% layer - Output layer
% Y – Predictions made by network
% T – Training targets
In otherwords, T is your labeled data (one per observation), and Y is the label predicted by your model (one per observation).
It depends what your input layer is, but I suspect the input size should be 28xN, where N is the number of observations in the mini-batch.


Find more on Sequence and Numeric Feature Data Workflows in Help Center and File Exchange




Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!