Invalid training data. Predictors and responses must have the same number of observations.
古いコメントを表示
I wan to train a LSTM.
But I get Error:
Error using trainNetwork (line 191)
Invalid training data. Predictors and responses must have the same number of observations.
layers = [ ...
sequenceInputLayer(6)
lstmLayer(120,'OutputMode','last')
fullyConnectedLayer(2)
softmaxLayer
classificationLayer];
options = trainingOptions('adam', ...
'MaxEpochs',20, ...
'MiniBatchSize',32, ...
'GradientThreshold',1, ...
'InitialLearnRate',0.005, ...
'Shuffle','every-epoch', ...
'Verbose',0, ...
'Plots','training-progress');
net = trainNetwork(XTrain, YTrain, layers, options);



採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Built-In Training についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!