How to specify the number of features rather than their size ?
1 回表示 (過去 30 日間)
古いコメントを表示
Hi there,
Please could anyone help me
I have 3 feautures with a column size of 361 each, how can i tell my LSTM neural network model that i have 3 features and not 1083 features ?matlab
Thanks in adavence
0 件のコメント
回答 (1 件)
Manish
2024 年 8 月 30 日
Hi ,
I understand that you want to define a LSTM with required number of features.
You can achieve this by using the “sequenceInputLayer” function and passing an input layer of the size that corresponds to the number of features in your data. In this case it is 3.
Refer to the below example code for better understanding.
numFeatures = 12;
numHiddenUnits = 100;
numClasses = 9;
layers = [ ...
sequenceInputLayer(numFeatures)
lstmLayer(numHiddenUnits,OutputMode="sequence")
fullyConnectedLayer(numClasses)
softmaxLayer];
Refer to the following documentation for more understanding of the “sequenceInputLayer” function and relevant code examples.
Hope it helps!
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Image Data Workflows についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!